Skip to main content



      Home
Home » Archived » BIRT » Problems with viewing report as PDF and also in Preview(View report as PDF)
Problems with viewing report as PDF and also in Preview [message #654834] Thu, 17 February 2011 06:22 Go to next message
Eclipse UserFriend
Hi everybody,

recently I have started to use Birt to create reports from a database of research groups.
I have detected some problems when generating a PDF and also when making a preview of the report, due to long lines that appear in the database.

In my report, the data from the groups are collected in a table. In some cell I have added a grid with all the information. The problem is that when making a preview or generating the PDF, in the cells of the grid only the first line is shown, the rest of the content is cut off.

If I choose the option "View as DOC" all the contents in the table are shown but I have to resize the cells.

Do anybody know how to solve this problem with the PDF generator?

Thank you very much for your help.

Best regards
Re: Problems with viewing report as PDF and also in Preview [message #654941 is a reply to message #654834] Thu, 17 February 2011 12:05 Go to previous messageGo to next message
Eclipse UserFriend
Is there any whitespace in the string? You may want to look at this:
//RE API method
http://dev.eclipse.org/newslists/news.eclipse.birt/msg30589. html
PDFRenderOption options = new PDFRenderOption();
options.setOption(IPDFRenderOption.PDF_HYPHENATION, true);
options.setOption(IPDFRenderOption.PDF_TEXT_WRAPPING, true);
options.setOutputFileName("output/resample/wordwrap.pdf");
options.setOutputFormat("pdf");

or
//javascript substring
http://www.birt-exchange.org/org/forum/index.php/topic/19827 -how-do-i-use-word-wrap-in-report-design/page__s__ad0bb32bbb ac95aee7b5556149417a73


Jason

On 2/17/2011 6:22 AM, Teresa Sanchez wrote:
> Hi everybody,
>
> recently I have started to use Birt to create reports from a database of
> research groups. I have detected some problems when generating a PDF and
> also when making a preview of the report, due to long lines that appear
> in the database.
>
> In my report, the data from the groups are collected in a table. In some
> cell I have added a grid with all the information. The problem is that
> when making a preview or generating the PDF, in the cells of the grid
> only the first line is shown, the rest of the content is cut off.
> If I choose the option "View as DOC" all the contents in the table are
> shown but I have to resize the cells.
>
> Do anybody know how to solve this problem with the PDF generator?
>
> Thank you very much for your help.
>
> Best regards
Re: Problems with viewing report as PDF and also in Preview [message #655456 is a reply to message #654941] Mon, 21 February 2011 03:58 Go to previous messageGo to next message
Eclipse UserFriend
Thank you Jason for your help, but I would like to know how to change the option in PDFRenderOption because I think that I don't have the source code.
I am using the the gui environment of Birt.
Again, thank a lot.

Regards,

Teresa.
Re: Problems with viewing report as PDF and also in Preview [message #655518 is a reply to message #654834] Mon, 21 February 2011 09:39 Go to previous messageGo to next message
Eclipse UserFriend
Hi Jason Weathersby,

Can you please explain how it script work and hot they get parameter - longStr and width?

function wrap(longStr,width){
length = longStr.length;
if(length <= width)
return longStr;
return (longStr.substring(0, width) + "\n" + wrap(longStr.substring(width, length), width));
Re: Problems with viewing report as PDF and also in Preview [message #655567 is a reply to message #655518] Mon, 21 February 2011 13:55 Go to previous messageGo to next message
Eclipse UserFriend
longStr I believe in that example is whatever you pass in as a value.
For example in an expression wrap(row["mydata"], 20)
Width is the max length you want the string to be before inserting a new
line.

Jason

On 2/21/2011 9:39 AM, Sergey wrote:
> Hi Jason Weathersby,
>
> Can you please explain how it script work and hot they get parameter -
> longStr and width?
>
> function wrap(longStr,width){
> length = longStr.length;
> if(length <= width)
> return longStr;
> return (longStr.substring(0, width) + "\n" +
> wrap(longStr.substring(width, length), width));
Re: Problems with viewing report as PDF and also in Preview [message #655568 is a reply to message #655456] Mon, 21 February 2011 13:56 Go to previous messageGo to next message
Eclipse UserFriend
Teresa,

Currently there is no option to change this in the Viewer unless you
modify the source for it. Can you log a bug for this?

Jason

On 2/21/2011 3:58 AM, Teresa Sanchez wrote:
> Thank you Jason for your help, but I would like to know how to change
> the option in PDFRenderOption because I think that I don't have the
> source code.
> I am using the the gui environment of Birt.
> Again, thank a lot.
>
> Regards,
>
> Teresa.
Re: Problems with viewing report as PDF and also in Preview [message #655683 is a reply to message #655568] Tue, 22 February 2011 04:57 Go to previous messageGo to next message
Eclipse UserFriend
Please explain where in report I need write this code?

PDFRenderOption options = new PDFRenderOption();
options.setOption(IPDFRenderOption.PDF_HYPHENATION, true);
options.setOption(IPDFRenderOption.PDF_TEXT_WRAPPING, true);
options.setOutputFileName("output/resample/wordwrap.pdf");
options.setOutputFormat("pdf");
Re: Problems with viewing report as PDF and also in Preview [message #655690 is a reply to message #655683] Tue, 22 February 2011 05:34 Go to previous messageGo to next message
Eclipse UserFriend
If you have any example please send me
kolomiec_sergey@mail.ru
Thanks!
Re: Problems with viewing report as PDF and also in Preview [message #655695 is a reply to message #655690] Tue, 22 February 2011 05:40 Go to previous messageGo to next message
Eclipse UserFriend
If you have any example please send me
kolomiec_sergey(at)mail.ru
Thanks!

[Updated on: Tue, 22 February 2011 05:41] by Moderator

Re: Problems with viewing report as PDF and also in Preview [message #655802 is a reply to message #655695] Tue, 22 February 2011 11:29 Go to previous messageGo to next message
Eclipse UserFriend
Are you using the API or the Viewer? If you are using the Viewer are
you going to modify the viewer source code?

Jason

On 2/22/2011 5:40 AM, Sergey wrote:
> If you have any example please send me kolomiec_sergey(at)mail.ru
> Thanks![/quote]
>
Re: Problems with viewing report as PDF and also in Preview [message #655932 is a reply to message #655802] Wed, 23 February 2011 06:24 Go to previous messageGo to next message
Eclipse UserFriend
What is "the API"? For viewer I am using Actuate iPortal. I have little experience in creating Birt report, if you have example, how I can modify the viewer source code, please give me it.
Thanks!
Re: Problems with viewing report as PDF and also in Preview [message #655934 is a reply to message #655802] Wed, 23 February 2011 06:36 Go to previous messageGo to next message
Eclipse UserFriend
No Message Body

[Updated on: Wed, 23 February 2011 06:39] by Moderator

Re: Problems with viewing report as PDF and also in Preview [message #655981 is a reply to message #655934] Wed, 23 February 2011 10:39 Go to previous messageGo to next message
Eclipse UserFriend
I mean the Report Engine API. What version of the Actuate iPortal are
you using?

Jason

On 2/23/2011 6:37 AM, Sergey wrote:
> Hi,
>
> What is "the API"? For view I am using "Actuate iPortal". If you have
> any example how use "the API" please give me it.
> Thanks!
Re: Problems with viewing report as PDF and also in Preview [message #656271 is a reply to message #655981] Thu, 24 February 2011 15:04 Go to previous messageGo to next message
Eclipse UserFriend
Actuate iPortal - 10.
I never use API. If you have any example please provide me.
Thanks!
Re: Problems with viewing report as PDF and also in Preview [message #656276 is a reply to message #656271] Thu, 24 February 2011 15:17 Go to previous messageGo to next message
Eclipse UserFriend
Sergey,

I did some checking and currently this is not supported in iPortal.

Jason

On 2/24/2011 3:04 PM, Sergey wrote:
> Actuate iPortal - 10.
> I never use API. If you have any example please provide me.
> Thanks!
Re: Problems with viewing report as PDF and also in Preview [message #656423 is a reply to message #656276] Fri, 25 February 2011 09:51 Go to previous messageGo to next message
Eclipse UserFriend
Are you have some information or example report or user guide about "API"?
Re: Problems with viewing report as PDF and also in Preview [message #656453 is a reply to message #656423] Fri, 25 February 2011 12:23 Go to previous message
Eclipse UserFriend
Sergey,

Currently this is not possible with the Actuate APIs.

Jason

On 2/25/2011 9:51 AM, Sergey wrote:
> Are you have some information or example report or user guide about "API"?
Previous Topic:Bar Chart vertical axis scaling question
Next Topic:HowTo - Scripting - Dinamically get Images...
Goto Forum:
  


Current Time: Wed Jul 23 14:13:54 EDT 2025

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

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

Back to the top