Jump to content
We've recently updated our Privacy Statement, available here ×

gogofe

Members
  • Posts

    6
  • Joined

  • Last visited

gogofe's Achievements

Rookie

Rookie (2/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Conversation Starter Rare

Recent Badges

0

Reputation

  1. Hy, I am using jasperreport to generate an excel file. I have designed the jrxml file with two columns and two textfields below them. One textfield may have large text and is designed to expand itself if the content doesnt fit to the original size. If I generate a pdf file, this textfield expands till the content fits into the cell but if I generate an excel file, this textfield expands but not enough to fit all the content of the texfield into the cell, why? Missing some property in jrxml file, or in java code? Thanks
  2. Hy, I dont get to print a line I have in my detail of a jrxml. For each result I print the date in one column and in the other column I print a text ; each result is separated from other result by a horizontal line but when the text of the second column is larger than the height configured for the the detail band, the horizontal line is not printed. I attach you an image explaining and the jrmxl file too. Thanks
  3. Hy, I want to control manually or change some configuration because in the pdf file I sent in the first post, the first page of this pdf you can see that results that should appear in the second page are showing in the first page so these results are mixing with the results of the first page and you cant see well the first page. When you say page break element you mean the next element?: <break> <reportElement x="0" y="14" width="782" height="0" key="element-1" stretchType="RelativeToTallestObject"> <printWhenExpression><![CDATA[boolean.valueOf(($V{lineIndex}.intValue() % 20) == 0)]]></printWhenExpression> </reportElement> </break> Is something wrong in this configuration? Thanks
  4. Hy, I have designed a report which is giving me problems when the results of the detail band are bigger than a page. I mean when the number of results are bigger than a page some of the results of the second page are showing in the first page so some of the results of the second page are mixing with the results of the first page (its very wierd) I attach you a pdf that shows this behaviour. Thanks
  5. Hy, I have these classes: public class Person { private String name; private List phones; getters and setters.... } public class Phone { private String number; getters and setters.... } I want to get a list of Person objects and send them to the jasperreport; I want it to show for each person name his phones. I have created a subreport inside the main report to show the phones. So I have two declarated fields in the main report: name as String object and phones as java.util.List, is this right?. If I open the subreport I have declarated as data source the next : "new JRBeanCollectionDataSource($F{phones})", is right? If I open the subreport I have one declarated field: number as String object, is right? So I have the main report "contacts.jrxml" and the subreport "phones.jrxml" in the same directory. But every time I try to generate the jasperreport like a pdf file, I get the next error: net.sf.jasperreports.engine.JRException: Could not load object from location : c:/.............phones.jrxml. I have a paremeter fo the jasperrepot to indicate what is route to find the subreport. Here is my java code to indicate it: File reportFile = new File(request.getSession(true).getServletContext().getRealPath( "/WEB-INF/reports/phones.jrxml")); HashMap params = new HashMap(); params.put("SUBREPORT_DIR",reportFile.getParent()+"\\"); The value of the SUBREPORT_DIR in the jasperreport is: $P{SUBREPORT_DIR}+"phones.jrxml" I tried many things changing the route of the subreport, changing the value of SUBREPORT_DIR so, the error is because its not finding the subreport or because there is an error in the main report or the subreport? Thanks a lot
×
×
  • Create New...