Search
Tuesday, January 06, 2009 ..:: Forum ::.. Register  Login
 
  Forum  Templates  Tags & Template...   Multiple xml data sources
Previous Previous
 
Next Next
New Post 1/23/2008 5:36 PM
Resolved
  rfligg
43 posts
7th Level Poster


Multiple xml data sources 

 Hi

I want to create one report (report.pdf) with one rtf template (test.rtf) but multiple xml data sources (house.xml and person.xml).
How do I run and merge these without using a java class?

I tried a silly example:
<wr:out select=”/house/bedrooms” datasource=”house.xml”/>
<wr:out select=”/person/name” datasource=”person.xml”/>

this is in my run.bat file
java net.windward.xmlreport.RunReport test.rtf report.pdf -xml name.xml -xml house.xml

the result was <wr:out/>

please help!

thank you

 
New Post 1/23/2008 5:36 PM
  rfligg
43 posts
7th Level Poster


Re: Multiple xml data sources 

 Hi;

What you need to do is:
<wr:out select=”/house/bedrooms” datasource=”house”/>
<wr:out select=”/person/name” datasource=”person”/>

code:
ProcessReport.processData(new Dom4jDataSource("house.xml"), "house");
ProcessReport.processData(new Dom4jDataSource("person.xml"), "person");

This level of indirection exists so that the xml file names can change and you only make a change in one place, not every tag.

 
Previous Previous
 
Next Next
  Forum  Templates  Tags & Template...   Multiple xml data sources
Membership Membership:
Latest New User Latest: GrahamA
New Today New Today: 0
New Yesterday New Yesterday: 0
User Count Overall: 56

People Online People Online:
Visitors Visitors: 1
Members Members: 0
Total Total: 1

Online Now Online Now:
All contents copyright (c) 2002 - 2008 by Windward Studios, Inc. All Rights Reserved.   Terms Of Use  Privacy Statement