Localize java.util.Collection, str( $P{paramCollection} )

0

Hey there !

Does anybody know how to localize a collection ?

I have a report with a multy-select-query assigned to it. I want to translate the selection / collection, but 

str( $P{paramCollection} ) does not work and resolves to an error:

"Error evaluating expression : Source text : $P{ParamAlarmtype} ? str( $P{ParamAlarmtype} ) : $R{Any alarmtype}

Any help appreciated !

EDIT:

For example.  $P{ParamAlarmtype} prints to [General, Safety, Transport, Message] , and i want it to be translated to (e.g. german)  [Allgemein, Sicherheit, Transport, Meldung] 

 

 

hankey86's picture
Joined: Jan 30 2012 - 2:11am
Last seen: 1 year 5 months ago
Maybe i should not have copied the whole expression... I just want to translate $P{ParamAlarmtype} $R{ $P{ParamAlarmtype} }does not work. str ( ${ParamAlarmtype} ) does not work. $P{ParamAlarmtype} e.g. prints [Safety, General, Transport] or [] or [Safety] or ... Hope this helps.
hankey86 - 6 years 11 months ago

1 Answer:

0

$P{ParamAlarmtype} ? str( $P{ParamAlarmtype} ) : $R{Any alarmtype}

In your above expression provide value for $P{ParamAlarmtype}

e.g

$P{ParamAlarmtype} == "ABC" ? str( $P{ParamAlarmtype} ) : $R{Any alarmtype} 

ajinkya_c's picture
935
Joined: Aug 29 2012 - 6:13am
Last seen: 2 years 8 months ago

Sry. I think you misunderstood me.
See my comment in the first post.

hankey86 - 6 years 11 months ago
Feedback