I have a Jasper "Report Book" created in JasperStudio. The book contains book_cover.jasper, table_of_contents.jasper, and two custom reports. This works great when I preview it in JasperStudio. When I copy all these files to my servoy server into the application_server\server\reports directory and attempt to run the report, I get "Resource not found at: book_cover.jasper.".
I'm running the report in Servoy using the code below.
- Code: Select all
function compileReport(event) {
application.updateUI(); //to make sure the Servoy window doesn't grab focus after showing the Jasper Viewer var
ds = forms.input1.foundset.getDataSource();
var d = ds.split('/');
var myServer = d[1];
//run this jasper report and pass the ssp_id as the parameter.
plugins.jasperPluginRMI.runReport(myServer, "My_Book.jasper", "c:\\temp\\my_book.pdf" , OUTPUT_FORMAT.PDF, {unique_id: forms.input1.unique_id});
//launch PDF file in Adobe Reader
application.executeProgram('rundll32', 'url.dll,FileProtocolHandler', 'c:/temp/my_book.pdf');
Instead of trying to run My_Book.jasper, if I replace that with book_cover.jasper, the cover page opens right up. So I know it's there in the right folder.
What do I need to do differently to run a report book?
thanks!