Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » Questions regarding use the __document report parameter and the viewer frameset option?
Questions regarding use the __document report parameter and the viewer frameset option? [message #822376] Fri, 16 March 2012 14:29 Go to next message
Mike Wulkan is currently offline Mike WulkanFriend
Messages: 147
Registered: July 2009
Senior Member
I have a header in my report that contains links to many sub-reports.
I would like to capture the rptdocument name when each report is rendered and save it in a session variable such that the links can be altered dynamically to use the rptdocument name if it exists to avoid the overhead of re-rendering previously rendered reports when the user wants to flip between the various sub-reports.

I have hit two obstacles so far:
1) When I put the following code in the beforeFactory of my report:

myAttributeBean = reportContext.getHttpServletRequest().getAttribute('attributeBean');
reportDoc = myAttributeBean.getReportDocumentName( );

reportDoc is always null

2) If I put the same code in a dynamic text element within the report, then reportDoc is null if I run the report using the run servlet because it doesn't create the rptDocument file; so I have to use the frameset servlet. However I don't want the "features" of the frameset. So I set the following parameters:

frameset?__showtitle=false&__toolbar=false&__navigationbar=false

Which almost gives me back the look that I want, except that it still insists on carving my report into pages. I want one long html web page like I get with the run servlet but I can't seem to find and option to turn off the paging?

So to summarize the questions:
1) Why can't I put the script in the beforeFactory method?
2) How do I turn off paging in the frameset viewer?
3) Is there a better way to achieve what I am attempting to do?


[Updated on: Fri, 16 March 2012 18:02]

Report message to a moderator

Re: Can you use the __document report parameter if you aren't using the viewer frameset option? [message #824400 is a reply to message #822376] Mon, 19 March 2012 16:17 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Mike

If you put a bookmark on the outer container, say like a table with a
bookmark of "mytable", you can add the following url parameters to turn
off pagination:

&__isreportlet=true&__bookmark=mytable

Have you tried the attribute script in the beforeRender? I do not think
the rpt document name is set before the before factory event.

Jason

On 3/16/2012 10:29 AM, Mike Wulkan wrote:
> I have a header in my report that contains links to many sub-reports.
> I would like to capture the rptdocument name when each report is
> rendered and save it in a session variable such that the links can be
> altered dynamically to use the rptdocument name if it exists to avoid
> the overhead of re-rendering previously rendered reports when the user
> wants to flip between the various sub-reports.
>
> I have hit two obstacles so far:
> 1) When I put the following code in the beforeFactory of my report:
>
> myAttributeBean =
> reportContext.getHttpServletRequest().getAttribute('attributeBean');
> reportDoc = myAttributeBean.getReportDocumentName( );
>
> reportDoc is always null
>
> 2) If I put the same code in a dynamic text element within the report,
> then reportDoc is null if I run the report using the run servlet because
> it doesn't create the rptDocument file; so I have to use the frameset
> servlet. However I don't want the "features" of the frameset. So I set
> the following parameters:
>
> frameset?__showtitle=false&__toolbar=false&__navigationbar=false
>
> Which almost gives me back the look that I want, except that it still
> insists on carving my report into pages. I want one long html web page
> like I get with the run servlet but I can't seem to find and option to
> turn off the paging?
>
> So to summarize the questions:
> 1) Why can't I put the script in the beforeFactory method?
> 2) How do I turn off paging in the frameset viewer?
> 3) Is there a better way to achieve what I am attempting to do?
>
>
>
Re: Can you use the __document report parameter if you aren't using the viewer frameset option? [message #824419 is a reply to message #824400] Mon, 19 March 2012 16:42 Go to previous messageGo to next message
Mike Wulkan is currently offline Mike WulkanFriend
Messages: 147
Registered: July 2009
Senior Member
Hi Jason,

So I tried

...frameset?__isreportlet=true&__bookmark=ReportBody&__showtitle=false&__toolbar=false&__navigationbar=false...

where I specified "ReportBody" on a Grid within my report design and now I get the following error


- org.eclipse.birt.report.service.api.ReportServiceException: Invalid bookmark : ReportBody.
AxisFault

faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException

faultSubcode:

faultString: org.eclipse.birt.report.service.api.ReportServiceException: Invalid bookmark : ReportBody.

faultActor:

faultNode:

faultDetail:

{http://xml.apache.org/axis/}stackTrace:org.eclipse.birt.report.service.api.ReportServiceException: Invalid bookmark : ReportBody.

at org.eclipse.birt.report.service.ReportEngineService.throwDummyException(ReportEngineService.java:1104)

at org.eclipse.birt.report.service.ReportEngineService.renderReportlet(ReportEngineService.java:1940)

at org.eclipse.birt.report.service.BirtViewerReportService.renderReportlet(BirtViewerReportService.java:337)

at org.eclipse.birt.report.service.actionhandler.BirtGetReportletActionHandler.doExecution(BirtGetReportletActionHandler.java:117)

at org.eclipse.birt.report.service.actionhandler.BirtGetReportletActionHandler.__execute(BirtGetReportletActionHandler.java:77)

at org.eclipse.birt.report.service.actionhandler.AbstractBaseActionHandler.execute(AbstractBaseActionHandler.java:90)

at org.eclipse.birt.report.presentation.aggregation.layout.FramesetFragment.doService(FramesetFragment.java:216)

at org.eclipse.birt.report.presentation.aggregation.layout.FramesetFragment.service(FramesetFragment.java:86)

at org.eclipse.birt.report.servlet.ViewerServlet.__doGet(ViewerServlet.java:181)

at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.doGet(BirtSoapMessageDispatcherServlet.java:160)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)

at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)

at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.service(BirtSoapMessageDispatcherServlet.java:122)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:304)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at org.eclipse.birt.report.filter.ViewerFilter.doFilter(ViewerFilter.java:68)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)

at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)

at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:929)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)

at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:405)

at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:964)

at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:515)

at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:302)

at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:897)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:919)

at java.lang.Thread.run(Thread.java:736)

Caused by: org.eclipse.birt.report.engine.api.EngineException: Invalid bookmark : ReportBody.

at org.eclipse.birt.report.engine.api.impl.RenderTask.setReportlet(RenderTask.java:370)

at org.eclipse.birt.report.service.ReportEngineService.renderReportlet(ReportEngineService.java:1931)

... 31 more

Re: Can you use the __document report parameter if you aren't using the viewer frameset option? [message #824438 is a reply to message #824419] Mon, 19 March 2012 17:12 Go to previous messageGo to next message
Mike Wulkan is currently offline Mike WulkanFriend
Messages: 147
Registered: July 2009
Senior Member
Hmmm, I tried again and now it seems to be working. So to make this technique work I would have to add an outer container that contained everything in my report, otherwise I'll only see what's in the container labelled with the specified bookmark, right? Too bad you can't assign a bookmark to the "body" element of a rptDesign. Now I'll have to modify all my rptDesign documents to enclose the whole body in a grid.

Do you have a feel for the performance implications of rendering the html using:

frameset?__isreportlet=true&__bookmark=ReportBody&__showtitle=false&__toolbar=false&__navigationbar=false

versus

run?
Re: Can you use the __document report parameter if you aren't using the viewer frameset option? [message #824518 is a reply to message #824438] Mon, 19 March 2012 19:14 Go to previous message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

Mike,

Without modifying the source I do not know of an easier way. I think
the performance should not be affected that much either way.

Jason

On 3/19/2012 1:12 PM, Mike Wulkan wrote:
> Hmmm, I tried again and now it seems to be working. So to make this
> technique work I would have to add an outer container that contained
> everything in my report, otherwise I'll only see what's in the container
> labelled with the specified bookmark, right? Too bad you can't assign a
> bookmark to the "body" element of a rptDesign. Now I'll have to modify
> all my rptDesign documents to enclose the whole body in a grid.
> Do you have a feel for the performance implications of rendering the
> html using:
>
> frameset?__isreportlet=true&__bookmark=ReportBody&__showtitle=false&__toolbar=false&__navigationbar=false
>
>
> versus
>
> run?
Previous Topic:Migration
Next Topic:Finding BIRT Report Developer 2.5.2
Goto Forum:
  


Current Time: Thu Apr 25 07:58:48 GMT 2024

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

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

Back to the top