Jump to content
Changes to the Jaspersoft community edition download ×

eraianbanc

Members
  • Posts

    11
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Everything posted by eraianbanc

  1. Hi, Set the propertfyfor JExcelApiExporter with true for IS_AUTO_DETECT_CELL_TYPE as shown in the code. Try it it will work. Code:JExcelApiExporter jExcelApiExporter = new JExcelApiExporter();jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_AUTO_DETECT_CELL_TYPE,Boolean.TRUE);
  2. Can any one please help us in gettting those Zeros also after the decimal pont when exported as excel. Only when i export the fiels as Double, i ll be able to calculate the sum,avg and all in the excel cells. Do i need to set any other parameter, while exporting it to excel.?? Rgds, Erai.
  3. Hi All, When i try to generate a report in XLS format, the zeros in the resultset after decimal point is not displayed when it is exported to xls Eg: Resultset 123.0000 123.2340 In Excel report im getting these values as 123 123.23 .We use JExcelApiExporter for eporting it to excel in the below code. Please suggest me how to handle the decima precision in Excel. I have this field as Double object. Code:Connection objDbCon = null; Map mpDetailSp; JasperPrint print = null;try {mpDetailSp = new HashMap();mpDetailSp.put("A I Laing Id",new Integer ("1")); objDbCon = getConnectionProcess("SERVERNAME","employees","devuser","devuser12$");mpDetailSp.put(JRParameter.IS_IGNORE_PAGINATION, true);print = JasperFillManager.fillReport("D:\\iRepors3.5.1_WS\\1841006_1_0_1.jasper", mpDetailSp, objDbCon);JExcelApiExporter jExcelApiExporter = new JExcelApiExporter(); jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, Boolean.TRUE); jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_AUTO_DETECT_CELL_TYPE,Boolean.TRUE);jExcelApiExporter.setParameter(JRExporterParameter.JASPER_PRINT, print); jExcelApiExporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME, "D:\\iRepors3.5.1_WS\\TEST_DECIMAL_PRECISION.xls"); jExcelApiExporter.exportReport();catch(Exception objException) { objException.printStackTrace(); } finally { objDbCon.close(); objDbCon = null; }
  4. Hi, Anyone please suggest me how do i do the sum for a comma separated values for which i have specified a pattern for that field when genearting the report to an Excel file. I can able to do it for that numbers which dont have commas in them. i.e . The fields which have the default format works fine for sum formlas in Excel. Can i tell the end customer not to use any commas pattern for those fields, so that he can be able to do the sum for the reports generated in excel format. Regards, Erai.
  5. This was the requirement from the client side that they need the comma separated formats, which can evaluate the sum also in MS Excel. Can anyone please help me out on this issue.
  6. Hi, I have using the following data to generate the report. In the Query i gave as 'Test_Commas_rtr 1', And im changing the Pattern for this field(num ) as ¤ #,##0.00, Rgds, Eraianban C After viewing the report in Excel, i cannot able to do sum of the values which are having commas in Excel. When I double click the comma separated values, then only i can able to do the sum in Excel. But for the numbers with normal pattern, i can able to do the sum. I use the below code for xls generation (JExcelApiExporter) Please help me out, how do get the sum formula for comma separated numbers in excel. Do i need to set any parameters other that what i have used to overcome this issue. Code:create table Test_Commas(num NUMERIC(10,3))INSERT INTO Test_Commas values (1)INSERT INTO Test_Commas values (23456)INSERT INTO Test_Commas values (7895)create proc Test_Commas_rtr(@a_i_lang_id int)asbeginselect num from Test_Commasend---- Java codeJExcelApiExporter jExcelApiExporter = new JExcelApiExporter(); jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, Boolean.TRUE); jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_AUTO_DETECT_CELL_TYPE,Boolean.TRUE); //jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_DETECT_CELL_TYPE, Boolean.TRUE); jExcelApiExporter.setParameter(JRExporterParameter.JASPER_PRINT, print); jExcelApiExporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME, "D:\NetBeanWS\JRXLS\bin\2986_1_0_1.xls");
  7. Thanks Teodor. Thanks a lot. Now we can able to generate large volume excel reports. This is the code that i have added and i have added jxl-2.6.jar reference. Now im able to go on with the current jasperreports-3.5.1.jar Code:JExcelApiExporter jExcelApiExporter = new JExcelApiExporter(); jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, Boolean.TRUE); jExcelApiExporter.setParameter(JExcelApiExporterParameter.IS_DETECT_CELL_TYPE, Boolean.TRUE);jExcelApiExporter.setParameter(JRExporterParameter.JASPER_PRINT, print); jExcelApiExporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME, strReportLocation);//Eg:D:\\Eclipse WorkSpace\\J2EE WS\\JRXLS\\src\\2670_1_0_1_JExcel.xlsjExcelApiExporter.exportReport();
  8. This problem got solved when i use jasperreports-1.3.1.jar and poi-2.0-final-20040126.jar; We got into this issue when we migrated jasperreports-1.3.1.jar to jasperreports-3.5.1.jar. I do not know weather there is any problem with MS Office which cannot able to read the XLS exported using net.sf.jasperreports.engine.export.JRXlsExporter in jasperreports-3.5.1.jar and poi-3.2-FINAL-20081019.jar. But the same is working with same MS Office but the XLS exported using net.sf.jasperreports.engine.export.JRXlsExporter in jasperreports-1.3.1.jar and poi-2.0-final-20040126.jar. Do I need to make my project compatible with jasperreports-1.3.1.jar for this particular large volume data in XLS??
  9. I have a problem when the excel report is generated with a huge data volume. It is throwing "excel cannot complete this task with available resources choose less data or close other appliactions". For less volume of data report is getting generated fine. We are using jasperreports-3.5.1.jar,poi-3.2-FINAL-20081019.jar for genarating the xls file as a report generated using jasper reports. JRXlsExporter is not throwing any exception. The file is getting generated but, it is not opening by saying the above error. Pls help me where could be the problem. Rgds, Eraianban C
  10. Hi teodord, Im getting the trace till Inside exporter..6.1 After that the code is not going to the corresponding catch block. It just exits out of the application. But i was expectiong either of these two trace trace().debug("Inside exporter:7..."); Or in the catch block trace().error("Exception::exportReport::"+e.getMessage()); Do i need to have office installed on the linux server for the export to xls to happen. But in Windows Server even without MS office application , the excel report is getting generated. What could be the problem. Regards, Eraianban. Code:trace().debug("Inside exporter..");exporter = new JRXlsExporter(); exporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, new Boolean("true"));exporter.setParameter(JRXlsExporterParameter.IS_AUTO_DETECT_CELL_TYPE, new Boolean("false"));exporter.setParameter(JRXlsExporterParameter.IS_AUTO_DETECT_CELL_TYPE, new Boolean("true"));exporter.setParameter(JRExporterParameter.JASPER_PRINT, print);exporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME, strOutputFile); try{ trace().debug("Inside exporter..6.1"); exporter.exportReport(); trace().debug("Inside exporter:7..."); }catch(Exception e){ trace().error("Exception::exportReport::"+e.getMessage()); throw e;}
  11. Dear All, The JRExporter when used in Windows OS it is working fine and it is generating report in XLS format. But when i execute it it Linux OS, XLS getting generated with 0kb. After debugging it was found that JRExporter exporter; exporter.exportReport(); is not getting executed. Sample Code: JRExporter exporter = null; exporter = new JRXlsExporter(); exporter.setParameter(JRXlsExporterParameter.IS_REMOVE_EMPTY_SPACE_BETWEEN_ROWS, new Boolean("true")); exporter.setParameter(JRXlsExporterParameter.IS_AUTO_DETECT_CELL_TYPE, new Boolean("false")); exporter.setParameter(JRXlsExporterParameter.IS_AUTO_DETECT_CELL_TYPE, new Boolean("true")); exporter.setParameter(JRExporterParameter.JASPER_PRINT, print); exporter.setParameter(JRExporterParameter.OUTPUT_FILE_NAME, strOutputFile); try{ exporter.exportReport(); //not executed } catch(Exception e) { throw e; } Please do the needful.
×
×
  • Create New...