Hello again,
Wednesday, December 17, 2003, 11:27:12 AM, you wrote:
PS> You have an encoding problem with your java files.
PS> It may be creating the java source with some encoding and
PS> compiling with another. This code should work regardless of the encoding:
PS> PdfReader reader = new PdfReader("c:/demo_ru.pdf");
PS> PdfStamper stamp = new PdfStamper(reader,
PS> new FileOutputStream("c:/filled_demo_ru2.pdf"));
PS> AcroFields form = stamp.getAcroFields();
PS> String s = "\u0414\u0416";
PS> byte b[] = s.getBytes("Cp1251");
PS> s = new String(b, "Cp1252");
PS> form.setField("ruvalue", s);
PS> stamp.close();
Finally, it works. Unicode -> Cp1251 -> Cp1252 -> the PDF TextBox.
Thank you very much!
--
Best regards,
Algirdas mailto:[EMAIL PROTECTED]
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions