can I print parameterDescription ?

 

Hi All !

I want to print parameterDescription + parameter value in Title section.
Is there some method to print it?
 

Thanks.

motl's picture
1
Joined: Jul 13 2011 - 4:41am
Last seen: 1 year 2 months ago

2 Answers:

You can print parameter value in tile band once your parameter gets matched agianst the field you are comparing with ,and then you just need to drag that field into title band. 

rubamushtaq's picture
Joined: Nov 13 2012 - 8:37pm
Last seen: 10 years 5 months ago

You'll need a custom scriptlet for that, $P{..} exposes the parameter value.

In the scriptlet you can write a method that does the following:

    public String getParameterDescription(String paramName) {
        JRFillParameter param = parametersMap.get(paramName);
        return param == null ? null : param.getDescription();
    }

Then you would do $P{REPORT_SCRIPTLET}.getParameterDescription("paramName") in the report.

Regards,

Lucian

lucianc's picture
87369
Joined: Jul 17 2006 - 1:10am
Last seen: 15 hours 56 min ago
Feedback
randomness