Anil, Is it possible for you to send me the RTF file you are using?
Thanks Howard ----- Original Message ---- From: Anil Kumar <[EMAIL PROTECTED]> To: Post all your questions about iText here <itext-questions@lists.sourceforge.net> Sent: Wednesday, February 20, 2008 6:23:56 PM Subject: Re: [iText-questions] RTF Merge I tried it but got this & similar exception for rtf file with images. java.lang.NumberFormatException: For input string: "‰P" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48 ) at java.lang.Integer.parseInt(Integer.java:447) at com.lowagie.text.rtf.parser.destinations.RtfDestinationShppict.handleCharact er(Unknown Source) at com.lowagie.text.rtf.parser.RtfParser.handleCharacter(Unknown Source) at com.lowagie.text.rtf.parser.RtfParser.parseChar(Unknown Source) at com.lowagie.text.rtf.parser.RtfParser.tokenise(Unknown Source) at com.lowagie.text.rtf.parser.RtfParser.importRtfDocument(Unknown Source) at com.lowagie.text.rtf.RtfWriter2.importRtfDocument(Unknown Source) at com.lowagie.text.rtf.RtfWriter2.importRtfDocument(Unknown Source) Regards Anil -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Howard Shank Sent: Thursday, 21 February 2008 2:46 AM To: Post all your questions about iText here Subject: Re: [iText-questions] RTF Merge Try it this way, rtfWriter.importRtfDocument(new FileReader("testfile_in.rtf")); Howard ----- Original Message ---- From: Anil Kumar <[EMAIL PROTECTED]> To: itext-questions@lists.sourceforge.net Sent: Wednesday, February 20, 2008 7:03:15 AM Subject: Re: [iText-questions] RTF Merge Thanks for the help Mark. I tried new source, but I am unable to find a way around encoding issue faced when using StringReader in writer2.importRtfDocument(reader); because image data are written as bytes and when converted to characters those data gets messed up and I get exception. Is this the correct way of importing RTF documents ? Thanks Anil -----Original Message----- From: Mark Hall [mailto:[EMAIL PROTECTED] Sent: Wednesday, 20 February 2008 3:24 PM To: Post all your questions about iText here Cc: Anil Kumar Subject: Re: [iText-questions] RTF Merge Hi, wait for the next release where the RTF import functionality has been massively improved (or compile yourself from the SVN source). The current release only supports very simple documents. Mark On 20 Feb 2008, at 03:32, Anil Kumar wrote: > Hi, > > I am trying to merge multiple RTF file in to one, file contains > mixture of > text and images. I tried using RtfDirectContent but colors and font > gets > mixed up and if I tried using importDocument then faced with > encoding issues > for RTF with images when using readers. Please help what is the > correct way > to merge RTF files. > > Thanks, > Anil > > > > > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > iText-questions mailing list > iText-questions@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/itext-questions > Buy the iText book: http://itext.ugent.be/itext-in-action/ ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/ ____________________________________________________________________________ ________ Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/ ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/ ____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/