Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » "cant re-generate content for MultiLineItem" exception with Dynamic Text elements
"cant re-generate content for MultiLineItem" exception with Dynamic Text elements [message #853974] Mon, 23 April 2012 14:25 Go to next message
ing omini is currently offline ing ominiFriend
Messages: 26
Registered: March 2012
Junior Member
Hi everybody,

I have a report title which should be created with:
static text + variable related to time interval

Example:
"Purchase (" + reportMonthString + ")";

where "reportMonthString" is a string variable, whose runtime value is set to "01/01/2012" for example.

If I use Dynamic Text element:
- the HTML preview is correct
- the PDF generation arises the following exceptions: "cant re-generate content for MultiLineItem" on each of these Dynamic Text elements

what's the issue?


Re: "cant re-generate content for MultiLineItem" exception with Dynamic Text eleme [message #854327 is a reply to message #853974] Mon, 23 April 2012 22:04 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Can you recreate the issue with a sample report so we can run and test
it? Post the sample here.

Jason

On 4/23/2012 10:25 AM, ing omini wrote:
> Hi everybody,
>
> I have a report title which should be created with:
> static text + variable related to time interval
>
> Example:
> "Purchase (" + reportMonthString + ")";
>
> where "reportMonthString" is a string variable, whose runtime value is
> set to "01/01/2012" for example.
>
> If I use Dynamic Text element:
> - the HTML preview is correct
> - the PDF generation arises the following exceptions: "cant re-generate
> content for MultiLineItem" on each of these Dynamic Text elements
>
> what's the issue?
>
>
>
Re: "cant re-generate content for MultiLineItem" exception with Dynamic Text eleme [message #854839 is a reply to message #854327] Tue, 24 April 2012 09:19 Go to previous messageGo to next message
ing omini is currently offline ing ominiFriend
Messages: 26
Registered: March 2012
Junior Member
I think I'me getting dumber and dumber, but I cannot find the attachment option.
Or maybe it is not enabled for this forum...
Re: "cant re-generate content for MultiLineItem" exception with Dynamic Text eleme [message #854840 is a reply to message #854839] Tue, 24 April 2012 09:22 Go to previous messageGo to next message
ing omini is currently offline ing ominiFriend
Messages: 26
Registered: March 2012
Junior Member
Confirmed! I am getting dumber ! Very Happy
The attachment option was not available only inside the quick reply.


Here is a sample report... I hope you can reproduce the issue with it.
Just as a short description.

1) in report initialize script I define a set of functions which are used inside the report (normally they are saved in an external lib, but to keep it simple I've made a copy and paste here)
2) always in report initialize script, the refdate parameter is read and used to set variables like lastDayOfInterval
3) in report body you can see that the functions are working but some exception is raised when I put the computed values inside dynamic text elements

Thanks
Re: "cant re-generate content for MultiLineItem" exception with Dynamic Te [message #855175 is a reply to message #854840] Tue, 24 April 2012 15:26 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

I could not get the report to run. BIRT complained about this line:

lastDayOfIntervalString = dateToString(lastDayOfIntervalString,
"dd/MM/yyyy");

This variable lastDayOfIntervalString is being used before it is defined.
BTW on a side note, you may want to move this to the beforeFactory as
initialize can be called many times depending on how the report is
executed and rendered. Another thing you may want to try is to rename
some of the functions with a prefix like my_dateToString as a test to
verify you are not getting a conflict with an existing function.

Jason



On 4/24/2012 5:22 AM, ing omini wrote:
> Confirmed! I am getting dumber ! :d
> The attachment option was not available only inside the quick reply.
>
>
> Here is a sample report... I hope you can reproduce the issue with it.
> Just as a short description.
>
> 1) in report initialize script I define a set of functions which are used inside the report (normally they are saved in an external lib, but to keep it simple I've made a copy and paste here)
> 2) always in report initialize script, the refdate parameter is read and used to set variables like lastDayOfInterval
> 3) in report body you can see that the functions are working but some exception is raised when I put the computed values inside dynamic text elements
>
> Thanks
Re: "cant re-generate content for MultiLineItem" exception with Dynamic Te [message #857056 is a reply to message #855175] Thu, 26 April 2012 07:55 Go to previous messageGo to next message
ing omini is currently offline ing ominiFriend
Messages: 26
Registered: March 2012
Junior Member
copy and paste erro while preparing the sample report...

line 123 of initialize script must be changed as follows:
lastDayOfIntervalString = dateToString(lastDayOfInterval, "dd/MM/yyyy");


by the way the same code is working in the sample report but not in the original report!
I will evaluate your suggestion about beforeFactory and name conflicts... maybe one of them could be the root cause of my problems!

Thanks again
Re: "cant re-generate content for MultiLineItem" exception with Dy [message #857684 is a reply to message #857056] Thu, 26 April 2012 19:17 Go to previous message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

I would remove one function at a time to see which is causing the issue.
You can also look in the workspace .metadata folder for a .log file to
see if you are getting anything in it. This also may be a js var scope
issue. Are all your functions returning variables or are you using
global js variables?

Jason

On 4/26/2012 3:55 AM, ing omini wrote:
> copy and paste erro while preparing the sample report...
>
> line 123 of initialize script must be changed as follows:
> lastDayOfIntervalString = dateToString(lastDayOfInterval, "dd/MM/yyyy");
>
> by the way the same code is working in the sample report but not in the
> original report!
> I will evaluate your suggestion about beforeFactory and name
> conflicts... maybe one of them could be the root cause of my problems!
>
> Thanks again
Previous Topic:Report Error when generating
Next Topic:Rotated axis labels in Windows
Goto Forum:
  


Current Time: Tue Jan 21 01:53:47 GMT 2020

Powered by FUDForum. Page generated in 0.01772 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top