JasperSoft Studio 5.6.1 Excel Macro Merge Template - macros

I am attempting to merge an excel exported file from Jaspersoft Studio 5.6.1 with a macro-enabled excel file. However, when I use the "Add JasperReports Server Resource", other file types are not permitted. What is the proper procedure for uploading macro.xls?
Is the macro file needed in the local studio folder structure and get compiled together with the .jrxml OR does it exist on the JasperServer as a resource that is retrieved when the report is executed? This is a requirement for us in order to produce a file with grouped/collapsed columns which is not supported by the native API's.
When I place the macro file on the JasperReports Server and provide the path in the properties of the report, I receive an error message:
net.sf.jasperreports.engine.JRException: Input stream not found at : /Folder/Resources/macro.xlt

Related

How to export jasper report to an existing excel file

I have an jasper report that I can easily export as an .xls (using preview function in jasper). However I want Jasper to export to an existing excel file (say in my desktop "~/Desktop/output.xls )
I think its something related to Interface XlsExporterConfiguration but I am not sure how or what to do. I'd like to do something like:
Start Jaspersoft Studio IDE.
Open JRXML file.
Run JRXML file to generate (preview) a report.
Click File >> Export >> Append to append report to an existing spreadsheet.
The File >> Export >> Append isn't how to do this from within the IDE. Is there a way?

Jaspersoft Server V5.5 Catalogue Import Creates Directories in Repository But No Reports, Import Controls, Or Queries Are Imported

I have a zip file created using the Export function in Jaspersoft Server V5.5. This zip file contains a catalogue of all reports, input controls, and queries from a development server.
When I try to import the catalogue to V5.5 on my production server by logging in as superuser and going to "Manage > Server Settings > Import", selecting the zip file, and clicking Submit, I receive an "Import Succeeded" message.
When I check the repository however, most of the directories have been created (but not the input control or queries folders) but none of the actual reports, input controls or queries have been imported.
What am I doing wrong? Do I need to modify any of the files within the zip file?

WCF: SvcUtil.exe with imports issue

One of the requirement in our project is as follows:
We got from client WSDL and XSD files only. Our task is to generate SOAP messages based on these WSDL and XSD files and extract SOAP bodies.
First step we should undertake is to generate client proxy files from given WSDL and XSD files. Main WSDL file has mulitple imports and imported XSD files also have some imports. I've tried to accomplish client proxy files generation by using SvcUtil.exe utility, but the error came up.
I ran SvcUtil.exe in this way:
E:\Projekti\WCF\XSD>svcutil /noconfig rosrazna.ru.xsd.SmevUnifoService.wsdl roskazna.ru.xsd.ResponseTemplate.xsd roskazna.ru.xsd.PGU_ImportRequest.xsd roskazna.ru.xsd.PGU_DataRequest.xsd roskazna.ru.xsd.PGU_ChargesResponse.xsd roskazna.ru.xsd.ExportPaymentsResponse.xsd roskazna.ru.xsd.ExportIncomesResponse.xsd roskazna.ru.xsd.ExportQuittanceResponse.xsd roskazna.ru.xsd.Ticket.xsd
But, this error came up:
Microsoft (R) Service Model Metadata Tool
[Microsoft (R) Windows (R) Communication Foundation, Version 3.0.4506.2152]
Copyright (c) Microsoft Corporation. All rights reserved.
Generating files...
Warning: No code was generated.
If you were trying to generate a client, this could be because the metadata docu
ments did not contain any valid contracts or services
or because all contracts/services were discovered to exist in /reference assembl
ies. Verify that you passed all the metadata documents to the tool.
Warning: If you would like to generate data contracts from schemas make sure to
use the /dataContractOnly option.
I have to mention I did not put imports from XSD files imported in main WSDL file in SvcUtil.exe command. I don't know how to put them.
So, how to solve this?
Thank you in advance.
Goran
#Goran, copy all the referenced xsd files to the same location as the wsdl. Then, when using the svcutil from command prompt, list all the xsds there, or put a *.xsd, like this:
E:\Projekti\WCF\XSD>svcutil /noconfig goransWsdl.wsdl *.xsd
PS: You already seem to be mentioning all the xsds though.

Generating crystal report in VS2010

I am getting an error while generating crystal report in vs2010. Error
The type 'CrystalDecisions.Web.CrystalReportViewer' exists in both 'c:\Windows\assembly\GAC_MSIL\CrystalDecisions.Web\13.0.2000.0__692fbea5521e1304\CrystalDecisions.Web.dll' and c:\Windows\assembly\GAC_MSIL\CrystalDecisions.Web\10.5.3700.0__692fbea5521e1304\CrystalDecisions.Web.dll
Open web.config and the static page of your aspx document. Both of them are containing different versions of assemblies. From web.config copy '13.0.2000.0' (version of assembly) and paste it in your aspx document's static page. The error has been removed.

How to use version control with JasperReports

We're about to start development of a number of reports using Jasper Server Reports version 3.7.0 CE.
Does anyone have any recommendations as to how best to manage version control with this development, given that the structure of the report units is managed in the database and through either iReport or the web front end?
In fact you can import/export to a directory structure using the js-import/js-export scripts, but then you can't edit these files directly with iReport.
Does anyone have any pointers?
This is problematic. I have established a subversion repository to allow standard reports delivery to be versioned but it is a real pain because jasper does not make this even a little bit easy.
I created a maven project with an assembly descriptor so that "src/main/xml/resources/Reports,adhoc,Domains, etc" can be packaged up in a zip that is pushed to our maven repository.
The biggest problem is that you can't just develop adhoc and input controls merely by modifying XML files. The developer has to import what is in source control into a working jasper server, modify the reports or add new ones (after making sure that his organization and datasources are configured) and once he's satisfied that the report(s) works, export the resources to a directory or zip file, manually modify all references in the exported files from datasources and organization specific resource locations back to "generic" before checking in his changes.
When importing into jasper, the same process has to be done in reverse. The generic paths and organization values have to be converted to the developer's organization so they can be easily imported/updated and he can prove out that the full "round trip" works properly before checking in.
To make the export/subversion checkin easier, I created an ant build file which lives in the maven project's root dir. The build prompts (or will read a properties file) to determine the exported zip location, the organization id of the exported tree. It then opens exported zip file from jasper, explodes it, performs text replacements on the files, resets the "createdDate" and "updatedDate" elements to something standard (so that the developer does not end up checking in files that haven't actually changed since jasper does not preserve the date values), and then copy the files into the subversion tree.
For the import process (from the subversion tree into jasper) we have a script that takes as input the organization id and then modifies the versioned xml files to the appropriate values so that the entire tree can be easily imported/updated into their organization.
The reason this level of complexity is required is to allow us to create the same standard reports in a multi-tenant environment, plus jasper's notion of deploying reports is absolutely bizarre. I'm not sure it would be possible to make this process more difficult if you were intending to do so.
If I was in your position I would have established this kind of process:
end of development session: export all reports to a directory structure in a project under version control
commit the project
before next development session: synchronize the project with svn repository
import directory structure to Jasper Server Reports
continue development
Not sure if someone found posted the solution.
This is what I have done for existing reports.
export reports from jasper server
modify file names from .data to .jrmxl
modify subreport calling to add extension (like in A.jrxml should have subreport name as B.jrxml
modify add .jrmxl to datafile,label and name in report unit xml files.
If you are creating new report on jasper server, it simple
give .jrxml to name and label while adding jrxml file. thats it.
Now you can work same files in local and import same to jasper server.