Thankyou for replying.
Sorry if I've been unclear, I'll try to elaborate!
The source data is in an normal .xls Excel sheet and it contains an Invoice.
I'm trying to extract the data from Excel using an xslt to create an xml for import into another system.
There are always 11 header rows. A ChargeAccount number is stored in the Excel Sheet at G7.
I am selecting data from row 12 to however many rows there are, and need to add the value in G7 to the data.
Everything else works ok, I'm trying to add the value in G7 to the rows with the xslt.
Code:
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes" />
<xsl:param name="Database" />
<xsl:param name="FS" />
<xsl:template match="/">
<InvoiceImport>
<xsl:attribute name="Database"><xsl:value-of select="$Database" /></xsl:attribute>
<xsl:attribute name="FS"><xsl:value-of select="$FS" /></xsl:attribute>
<!-- I think I need to find the G7 value here-->
<LineItems><xsl:for-each select="//Row[position() > 11]">
<InvoiceLines>
<!--I need to use it here ? -->
<ChargeAccount><xsl:value-of select="G7 value ?????" /></ChargeAccount>
<CustomerNo><xsl:value-of select="Cell[@FieldNo = 7]" /></CustomerNo>
<InvoiceDate><xsl:value-of select="Cell[@FieldNo = 6]" /></InvoiceDate>
<Reference><xsl:value-of select="Cell[@FieldNo = 8]" /></Reference>
<Service><xsl:value-of select="Cell[@FieldNo = 4]" /></Service>
<NetCharge><xsl:value-of select="Cell[@FieldNo = 27]" /></NetCharge>
<TaxCharge><xsl:value-of select="Cell[@FieldNo = 29]" /></TaxCharge>
</InvoiceLines>
</LineItems>
</InvoiceImport>