[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Problem transforming Excel XML Workbook (or how to
Nacho Jimenez wrote:
Dear all, This is OT, but you don't really need XSL for this if you can deal with XML Schema. Excel has a cool ability to take an XML Schema as a 'map'. For example a schema for your spreadsheet would probably look like: <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> <xs:element name="programas"> <xs:complexType> <xs:sequence> <xs:element name="program" maxOccurs="unbounded"> <xs:complexType> <xs:sequence> <xs:element name="name" type="xs:string" maxOccurs="1"/> <xs:element name="line" type="xs:string" maxOccurs="1"/> <xs:element name="company" type="xs:string" maxOccurs="1"/> </xs:sequence> </xs:complexType> </xs:element> </xs:sequence> </xs:complexType> </xs:element> </xs:schema> You would import the schema as an XML Map. Then select the cells for a particular element and drop that element on the selection. Then hit Data -> Export and your done. best, -Rob <snip/>[....] <Row> <Cell><Data ss:Type="String">E-TF-010-16425</Data></Cell> <Cell><Data ss:Type="String">B38379715</Data></Cell> <Cell><Data ss:Type="String">X</Data></Cell> <Cell><Data ss:Type="String">S</Data></Cell> <Cell><Data ss:Type="Number">11144.55</Data></Cell> <Cell ss:Index="16"><Data ss:Type="String">AGP</Data></Cell> <Cell><Data ss:Type="String">Po</Data></Cell> </Row> <Row> <Cell><Data ss:Type="String">E-TF-012-09930</Data></Cell> <Cell><Data ss:Type="String">B38037511</Data></Cell> <Cell><Data ss:Type="String">X</Data></Cell> <Cell><Data ss:Type="String">S</Data></Cell> <Cell ss:StyleID="s45"><Data ss:Type="Number">15734.4</Data></Cell> <Cell><Data ss:Type="String">X</Data></Cell> <Cell ss:Index="16"><Data ss:Type="String">AGP</Data></Cell> <Cell><Data ss:Type="String">Po</Data></Cell> </Row> [...] <programas> <name>E-TF-012-09930</name> <line>Po</line> <company>AGP</company> </programas>
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|