Reputation: 11
Im pretty new to JasperReport Server. I have had success using JasperReport Sever 4.7(Community edition) and calling jasper reports (using jasperviewer)from within a java application.
My problem is: 1. To create my own parameter form which pops up when a user clicks a button linking to a jasper report.
Any assistance would be highly appreciated.
Upvotes: 1
Views: 2681
Reputation: 8816
For the first, when you create your report and save in your Jasper repository -
Just right-clik the report folder (the one containing your Main.jrxml) and click on Properties
. A dialog box appears.
Go to Other
tab. Next to Controls Layout
label there will be a drop-down box. Select Pop-up Screen
on that. Your job is done.
For the second, you can definitely have a select list. There are two ways to generate values for the list - by using a query or entering manually. The steps are:
In your report folder in the repository, under your main.jrxml file there will be an Input Controls
folder. Right click on it and click on Create a local input control
. A dialog box will appear.
On the General
tab give the ID and name for the input control (ID must match to your respective parameter name).
Go to Input Control Details
tab. Select type as "Single Select Query" or "Single Select List of Values" as per your requirements. Enter the query or values and your job is done.
Upvotes: 1