|Newbie: Add new Element to report [message #682126]
||Fri, 10 June 2011 09:16
Registered: June 2011
I am new to birt. So thank you for your patience. May be this was posted many times I didn't find it via google.
Here is the problem:
There is a webservice. I made a report with the Birt Report Designer 2.6.2 and these webservice is the scripted datasource. Via the open-Methode of the dataset I call the webservice and via the fetch-Methode the values the webservice transmitted get written to the OutputColumns.
One of the values the webservice sends is an array. The length of the array is variable. I know the length of the array in the fetch-Methode. So there is the point where I should add elements to the report in dependence of the length of the array. So I have found the Birt Programmers Reference and some code snippets via google.
Now I want to add some script to my report to dynamically add elements to my report. I searched for a global object to get to the report object with some kind of methods to add some elements.
I have found the class SessionHandle that I need for ReportDesignHandle with wich I can get the ElementFactory to create new Report-Elements. But I have difficulties with the session. I need a ReportDesignHandle that I can get from the SessionHandle but this SessionHandle I can only get via the createDesign()-Methode. But this means create a new report. And I think I don't need a new report. There is alreade a report created but I don't know how to catch him.
Thanks for any help in advance.
Powered by FUDForum
. Page generated in 0.03678 seconds