Hi,

I'm beginner in FOP. I have a problem with windows-1250 encoding. My source XML
documents looks like this:

<?xml version="1.0" encoding="windows-1250"?>
     <did>7 3 4 12 15 16 122</did>
     <acc>2613233761</acc>
     ...
     ...

I use xsl-fo document to transform source document to plain text:

<?xml version="1.0" encoding="windows-1250"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
                xmlns:fo="http://www.w3.org/1999/XSL/Format";
                version="1.0">

<xsl:output encoding="windows-1250"/>

<xsl:template match="sttmt">
   <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format";>
   ...
   ...

but result text file is not encoded in "windows-1250". My own code sequence
doesn't throw exception during execution:

     Driver driver = new Driver();
     driver.setRenderer(Driver.RENDER_TXT);
     driver.setOutputStream(new FileOutputStream("result.txt"));
     InputHandler inputHandler = new XSLTInputHandler(xmlFile, xslFile);
     driver.render(inputHandler.getParser(), inputHandler.getInputSource());

although it does'n run properly. Can you tell me how could I solve this?

Thank you for helping,

Kristian Keseli


Reply via email to