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

jasperreport & struts


ceriise

Recommended Posts

  • Replies 8
  • Created
  • Last Reply

Top Posters In This Topic

I am doing something very similar. If you have downloaded JasperServer, run the "ant" build of the java-web-app example, deploy it and make the necessary changes. The functionality is very similar in struts.

 

I am looking for implementation of the WSClient code, to use in my app, please reply if you find anything relevant to this.

Link to comment
Share on other sites

  • 2 weeks later...

I made changes to each of the jsp's that were included to integrate with my ActionForm's. Then I wrote my Action classes to do whatever processing needed to be done.

 

(This is usually the way that struts is used in a web app)

 

If you have anymore questions I'll try my best to answer.

 

Good luck.

 

Code:


JSP -> ACTIONFORM -> ACTION -> FORWARD -> NEWJSP

 

;)

Link to comment
Share on other sites

  • 2 weeks later...

Hello ceriise,

 

Actually I have solved my previous issue, but I do have a new problem that I could use some help on.

 

My requirement is to generate a report "asynchronously".

The user should have the ability to navigate throughout the application while the report is being generated. I have seen similar functionality in the JasperServer download source, but I am unsure as to how to implement this using Ajax/Struts. As of now I am able to submit an asynchronous request to my Action. Now I just need to know how to execute the report from my Action class asynchronously.

 

Everywhere I have searched, I have found that ppl are using threads/queues to do this, but it isn't explicit on exactly how this is integrated into Struts.

 

Please help... :unsure:

Link to comment
Share on other sites

hello,

what's the action that lounches your report?

I have a problem too B) Here is the issue: the button that generates the report works only once!!! My requirement is to let the user customize its report: choose the columns to be printed, the size of the columns, the printing (landscape or normal), the format ....

So this very nice button that does this works only once, meaning if for example I want to change something in my report and launche it again to generate a new report, it does not work and gives an error page.

Do you have an idea about that?

Link to comment
Share on other sites

It sounds like you may need to debug your request. So run your app in debug, and set a breakpoint as soon as you enter the Action class. Look at your request's attribute, and parameter values, make sure that the request has the right details to run the report more than once...

 

Remember, that once a request has been submitted and responded to, it is no longer active, meaning that all of its values are GONE. Try starting there and see what you can determine. Thats my suggestion.

 

:huh:

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...