Page 1 of 1

extraction out of crystal report xml file

Posted: Thu Mar 01, 2007 10:48 am
by Ike
How can I extract the content fieldname, value to a textfile ?
I haven't seen this type of xml before.
Normally I just put the xmlstructure in the description of the xmlinput stage. That doesn't work here.
The xml is this :

<?xml version="1.0" encoding="UTF-8" ?>
<FormattedReport xmlns = 'urn:crystal-reports:schemas' xmlns:xsi = 'http://www.w3.org/2000/10/XMLSchema-instance'
>
<FormattedAreaPair Level="0" Type="Report">
<FormattedAreaPair Level="1" Type="Details">
<FormattedArea Type="Details">
<FormattedSections>
<FormattedSection SectionNumber="0">
<FormattedReportObjects>
<FormattedReportObject xsi:type="CTFormattedField" Type="xsd:decimal" FieldName="{PRODUCT_RECORDS.PR_ID}"><ObjectName>Field1</ObjectName>
<FormattedValue>725928</FormattedValue>
<Value>725928.00</Value>
</FormattedReportObject>
<FormattedReportObject xsi:type="CTFormattedField" Type="xsd:string" FieldName="{PRODUCT_RECORDS.PRODUCT_TYPE}"><ObjectName>Field2</ObjectName>
<FormattedValue>1</FormattedValue>
<Value>1</Value>
</FormattedReportObject>
<FormattedReportObject xsi:type="CTFormattedField" Type="xsd:string" FieldName="{PRODUCT_RECORDS.PRODUCT_IND}"><ObjectName>Field6</ObjectName>
<FormattedValue>5</FormattedValue>
<Value>5</Value>
...