Wow das ging ja schnell mit den Antworten.
@Karolus: Das mit dem Suchen und Ersetzten geht ja wirklich, man sollte sich das Fenster mal genauer anschauen und die erweiterte Optionen auch benutzen

Danke so gehts schomal.
@Gert Seler: Das hatte ich auch schon probiert, war aber keine wirklich schöne Lösung für mich weil ich dann nochmal die Werte kopieren musste. Danke trotzdem.
@hol.sten: Das ist natürlich das beste, leider nicht nutzbar bzw. ich weiss nicht wie. Bin nicht so top in xslt, vielleicht weiss es ja einer. Es ist halt so das im ersten "Run" in den "Fight"-Tags keine Zahlen sondern Text steht, daher kann ich das so nicht verwenden von dir.
Das mit den XML und XSLT Dateien wollt ich mir schenken die erst umzuformatieren zum posten. Habs aber mal gemacht jetzt weil es wohl wirklich hilft eine optimale Lösung zu finden.
XML Datei. Die Struktur ist leider so vorgegeben, sonst würd ich da wohl auch das ein oder andere ändern. Ist hier aber nicht möglich weil die nicht von mir stammt ;(
Code: Alles auswählen
<?xml version="1.0"?>
<Report>
<Row>
<Heading>Damage/sec</Heading>
<Fight2>Enemy 1</Fight2>
<Fight3>Enemy 2</Fight3>
</Row>
<Row>
<Heading>Char 1</Heading>
<Fight2>179</Fight2>
<Fight3>303</Fight3>
</Row>
<Row>
<Heading>Char 2</Heading>
<Fight2>258</Fight2>
<Fight3>429</Fight3>
</Row>
</Report>
Und die XSLT Datei für den Import
Code: Alles auswählen
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<office:document-content xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" office:version="1.0">
<office:body>
<office:spreadsheet>
<table:table>
<table:table-row>
<table:table-cell>
<text:p>
<xsl:value-of select="Heading"/>
</text:p>
</table:table-cell>
</table:table-row>
<xsl:for-each select="Report/Row">
<table:table-row>
<table:table-cell>
<text:p>
<xsl:value-of select="Heading"/>
</text:p>
</table:table-cell>
<table:table-cell>
<text:p>
<xsl:value-of select="Fight2"/>
</text:p>
</table:table-cell>
<table:table-cell>
<text:p>
<xsl:value-of select="Fight3"/>
</text:p>
</table:table-cell>
</table:table-row>
</xsl:for-each>
</table:table>
</office:spreadsheet>
</office:body>
</office:document-content>
</xsl:template>
</xsl:stylesheet>
Wow das ging ja schnell mit den Antworten.
@Karolus: Das mit dem Suchen und Ersetzten geht ja wirklich, man sollte sich das Fenster mal genauer anschauen und die erweiterte Optionen auch benutzen ;) Danke so gehts schomal.
@Gert Seler: Das hatte ich auch schon probiert, war aber keine wirklich schöne Lösung für mich weil ich dann nochmal die Werte kopieren musste. Danke trotzdem.
@hol.sten: Das ist natürlich das beste, leider nicht nutzbar bzw. ich weiss nicht wie. Bin nicht so top in xslt, vielleicht weiss es ja einer. Es ist halt so das im ersten "Run" in den "Fight"-Tags keine Zahlen sondern Text steht, daher kann ich das so nicht verwenden von dir.
Das mit den XML und XSLT Dateien wollt ich mir schenken die erst umzuformatieren zum posten. Habs aber mal gemacht jetzt weil es wohl wirklich hilft eine optimale Lösung zu finden.
XML Datei. Die Struktur ist leider so vorgegeben, sonst würd ich da wohl auch das ein oder andere ändern. Ist hier aber nicht möglich weil die nicht von mir stammt ;(
[code]<?xml version="1.0"?>
<Report>
<Row>
<Heading>Damage/sec</Heading>
<Fight2>Enemy 1</Fight2>
<Fight3>Enemy 2</Fight3>
</Row>
<Row>
<Heading>Char 1</Heading>
<Fight2>179</Fight2>
<Fight3>303</Fight3>
</Row>
<Row>
<Heading>Char 2</Heading>
<Fight2>258</Fight2>
<Fight3>429</Fight3>
</Row>
</Report>[/code]
Und die XSLT Datei für den Import
[code]<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<office:document-content xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" office:version="1.0">
<office:body>
<office:spreadsheet>
<table:table>
<table:table-row>
<table:table-cell>
<text:p>
<xsl:value-of select="Heading"/>
</text:p>
</table:table-cell>
</table:table-row>
<xsl:for-each select="Report/Row">
<table:table-row>
<table:table-cell>
<text:p>
<xsl:value-of select="Heading"/>
</text:p>
</table:table-cell>
<table:table-cell>
<text:p>
<xsl:value-of select="Fight2"/>
</text:p>
</table:table-cell>
<table:table-cell>
<text:p>
<xsl:value-of select="Fight3"/>
</text:p>
</table:table-cell>
</table:table-row>
</xsl:for-each>
</table:table>
</office:spreadsheet>
</office:body>
</office:document-content>
</xsl:template>
</xsl:stylesheet>[/code]