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

Problems with charting and JRMapArrayDataSource


midrag

Recommended Posts

Hello,

 

i am passing JRMapArrayDataSource to the fillmanager. In the datasource i´ve got two values as String (one is casted from Integer to String to pass it as a map).

 

I can display both values in a simple Report without charting.

 

Now i want to do a pie chart with these two values. The report compiles fine, but the fillmanager throws an JRException saying that he has problems evaluating the expression for the Value-Field of the PieChart.

 

 

I declared the Field as java.lang.Object and cast it to Integer in the value-Expression field:

Code:
<valueExpression><!(java.lang.Integer) [CDATA[$F{Interger_as_String_Field}]]></valueExpression>

 

but it still throws a JRException saying that he has problems evaluating the expression for the Value-Field of the PieChart.

So how can i chart from a JRMapArrayDataSource with the values passed as Strings?

 

I have the feeling that i am overlooking something essential. Can someone point me to the right direction?

 

best regards,

 

midrag

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

solved my problems.

 

Code:
Integer.valueOf($F{Number_as_String_Field})

 

now i am able to chart from BeanDataSources :-).

 

Still i am confused why the engine cant handle:

 

Code:
[code]Integer.parseInt($F{Number_as_String_Field})

 

best regards,

 

midrag

Post edited by: midrag, at: 2006/11/06 08:58

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...