Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » Location of the figures
Location of the figures [message #638385] Thu, 11 November 2010 07:09 Go to next message
Missing name Missing name is currently offline Missing name Missing name
Messages: 55
Registered: July 2010
Member
Hello,

I designed the report template x.rptdesign with the Eclipse and added the image file in the shared resources. In the xml source is:

<expression name="uri" type="constant">reports/test.jpg</expression>


I can run the report with java and place the x.rptdesign and test.jpg in the same folder outside of the Eclipse project. What is the Eclipse folder "reports" in the xml source? How the BIRT runtime locates the figures? Is the functioning documented somewhere? It seems little bit confusing that there is "report" folder and it is not needed in the runtime.

Thanks,

Mika
Re: Location of the figures [message #638525 is a reply to message #638385] Thu, 11 November 2010 14:53 Go to previous messageGo to next message
Jason Weathersby is currently offline Jason Weathersby
Messages: 9167
Registered: July 2009
Senior Member

Mika,

Did you create a directory in the resource folder called report within
your design environment?

To set the resource folder outside of eclipse you will need to do the
following:

If you are using the BIRT Viewer set the resource folder in the web.xml
or use the __resourceFolder url parameter.

If you are using the BIRT API use code similar to:
EngineConfig config = new EngineConfig( );
config.setResourcePath("C:\\work\\resources");

Jason

On 11/11/2010 2:10 AM, Mika wrote:
> Hello,
>
> I designed the report template x.rptdesign with the Eclipse and added
> the image file in the shared resources. In the xml source is:
>
> <expression name="uri" type="constant">reports/test.jpg</expression>
>
>
> I can run the report with java and place the x.rptdesign and test.jpg in
> the same folder outside of the Eclipse project. What is the Eclipse
> folder "reports" in the xml source? How the BIRT runtime locates the
> figures? Is the functioning documented somewhere? It seems little bit
> confusing that there is "report" folder and it is not needed in the
> runtime.
>
> Thanks,
>
> Mika
Re: Location of the figures [message #638691 is a reply to message #638525] Fri, 12 November 2010 08:36 Go to previous message
Missing name Missing name is currently offline Missing name Missing name
Messages: 55
Registered: July 2010
Member
Hello,

I changed in the designer the preference Report Design -> Resource to the:

<Current Project Folder>\reports


and now the templates and figures outside of the template are working in my custom Servlet.

There was no need to use

config.setResourcePath


because the templates and figures are in the same folder.

BR,

Mika

PS. it's strange that before this modification the stand alone Java program worked without this preference setting, but not the servlet
Previous Topic:Printing report from web viewer
Next Topic:Birt and Questions
Goto Forum:
  


Current Time: Fri Oct 24 18:07:35 GMT 2014

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

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