My XML:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<ns0:Study xmlns:ns0="http://www.clientname.com/Site">
<ns0:StudyNum>XA123654</ns0:StudyNum>
<ns0:InformationContained>Full</ns0:InformationContained>
<ns0:StudyRowId>1-SETYE9</ns0:StudyRowId>
<ns0:ListOfSite>
<ns0:Site>
<ns0:SiteNum>12345</ns0:SiteNum>
<ns0:SiteName>University Name</ns0:SiteName>
<ns0:CountryCode>CA</ns0:CountryCode>
<ns0:SiteRowId>1-TYU7ER</ns0:SiteRowId>
</ns0:Site>
</ns0:ListOfSite>
</ns0:Study>
Code: Select all
<project name="xml to excel" mainModule="Main" version="2.0" logLevel="verbose">
<module name="Main">
<xmlRead file="\userdata\2016_part.xml" validation="none" processedInputFilesVariable="toExcel" version="1.0" logLevel="debug">
<rowset name="data">
<column index="1" value="/Study" />
<column index="2" value="/Study/StudyNum" />
<column index="3" value="/Study/StudyNum/InformationContained" />
<column index="4" value="/Study/StudyNum/InformationContained/StudyRowId" />
....
</rowset>
</xmlRead>
<writeExcel inputRowSetVariable="${data}" outputFile="\userdata\fromXML.xlsx" whenFileExists="overwrite" excelFormat="excel2007" includeHeadings="true" version="2.0" />
</module>
</project>
error:
When building rowset "data", the root element did not match in the file