>From my brief reading, it should work... Can you attach the PDF? I'm guessing the text is behind the RichMedia...
--Mark Storer Senior Software Engineer Cardiff.com import legalese.Disclaimer; Disclaimer<Cardiff> DisCard = null; > -----Original Message----- > From: dhryvastov [mailto:dhryvas...@serena.com] > Sent: Friday, August 20, 2010 7:13 AM > To: itext-questions@lists.sourceforge.net > Subject: [iText-questions] Unable to add Paragraph after > addingPdfAnnotation to the document. > > > Hello - > > I faced with such am interesting issue: > I have added PdfAnnotation to my Document. I need this for > embedding Fusion Chart graph into my pdf file. > The code that I use is: > //---------------------------------- > Document document = new Document(); > PdfWriter writer = PdfWriter.getInstance(document, pdf); > writer.setPdfVersion(PdfWriter.PDF_VERSION_1_7); > > writer.addDeveloperExtension(PdfDeveloperExtension.ADOBE_1_7_E XTENSIONLEVEL3); > document.open(); > > addReportTitle(report.getName(), document); > addTimeOfGeneration(document); > > RichMediaAnnotation richMedia = new > RichMediaAnnotation(writer, new Rectangle(36, 370, 559, 776)); > > PdfFileSpecification fs = > PdfFileSpecification.fileEmbedded(writer, > null, "hello", > convertStreamToByteArray(swf)); > > PdfIndirectReference asset = > richMedia.addAsset("RichGraphicalReport", fs); > > RichMediaConfiguration configuration = new > RichMediaConfiguration(PdfName.FLASH); > RichMediaInstance instance = new > RichMediaInstance(PdfName.FLASH); > RichMediaParams flashVars = new RichMediaParams(); > > InputStream transformedXML = getXSLTransformedXML(new > ByteArrayInputStream(xmlString.getBytes("UTF-8")), xsl); > String vars = > "&dataXML=".concat(convertStreamToString(transformedXML)); > flashVars.setFlashVars(vars); > instance.setParams(flashVars); > instance.setAsset(asset); > configuration.addInstance(instance); > > PdfIndirectReference configurationRef = > richMedia.addConfiguration(configuration); > > RichMediaActivation activation = new RichMediaActivation(); > activation.setConfiguration(configurationRef); > richMedia.setActivation(activation); > > PdfAnnotation richMediaAnnotation = > richMedia.createAnnotation(); > richMediaAnnotation.setFlags(PdfAnnotation.FLAGS_PRINT); > writer.addAnnotation(richMediaAnnotation); > //---------------------------------- > > After that I want to add new Paragraph (after the swf > embedded but I can't do this). The following code is added > but is not working: > //---------------------------------- > Paragraph footer = new Paragraph("My text", > getFont(6, Font.NORMAL)); > footer.setSpacingBefore(360); > footer.setIndentationLeft(55); > document.add(footer); > //---------------------------------- > > Could anybody tell me some ideas how to achieve this? > > Any help is greatly appreciated! > > Thanks in advance, > - Denys > -- > View this message in context: > http://itext-general.2136553.n4.nabble.com/Unable-to-add-Parag raph-after-adding-PdfAnnotation-to-the-document-> tp2332542p2332542.html > Sent from the iText - General mailing list archive at Nabble.com. > > -------------------------------------------------------------- > ---------------- > This SF.net email is sponsored by > > Make an app they can't live without > Enter the BlackBerry Developer Challenge > http://p.sf.net/sfu/RIM-dev2dev > _______________________________________________ > iText-questions mailing list > iText-questions@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/itext-questions > > Buy the iText book: http://www.itextpdf.com/book/ Check the > site with examples before you ask questions: > http://www.1t3xt.info/examples/ You can also search the > keywords list: http://1t3xt.info/tutorials/keywords/ > > > No virus found in this incoming message. > Checked by AVG - www.avg.com > Version: 9.0.851 / Virus Database: 271.1.1/3068 - Release > Date: 08/19/10 23:35:00 > ------------------------------------------------------------------------------ This SF.net email is sponsored by Make an app they can't live without Enter the BlackBerry Developer Challenge http://p.sf.net/sfu/RIM-dev2dev _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://www.itextpdf.com/book/ Check the site with examples before you ask questions: http://www.1t3xt.info/examples/ You can also search the keywords list: http://1t3xt.info/tutorials/keywords/