Congor Posted January 19, 2007 Share Posted January 19, 2007 Hi, ive got a huge problem and would really appreciateany help from you. i just created a JRTableModelDataSource from areal TableModel I also know how to make tables in iReport. The problem is, that i dont know what I have to writeinto the "Text Field Expression" Field to get the values out of my TableModel. In the demo/samples/tables example are only string constants. I get already an output consisting of exactly 13 rows, as my tableModel delivers but they are set to null, cause i dont know what to write into Text Field Expression. GreetsYVes Link to comment Share on other sites More sharing options...
Congor Posted January 19, 2007 Author Share Posted January 19, 2007 Ok, got it again. For all searching sucha a solution: The TableModel Interface (not JRTableModelDataSource) defines a function: String getColumnName(int columnIndex) which returns the name of the column specified withthe index. All one has to do is to check, which names are returned by this function. In my case it were 1. "Name [de]"2. "Name [en]" So in iReport i created two Fields (-in the library-) and called them Name[de] and Name[en]. Then i assigned the values $F{Name [de]} to the first TextField$F{Name [en]} to the 2nd TextField (In fact into the "Text Field Expression"of my TextFields) Hope, that this will help anyone GreetsYves Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now