Paulo, Thanks for the reply..Not sure how I can pass HyperLinkKey.KEY_INSTANCE as its not accessible. I dont see any documentation on that too.
Also,I looked at setRenderingHint(Key,Object) and dont see what value to pass for Key. Is that the value of text element in the table? Maybe an example would help.. Thanks again, -SaurabhPaulo aerogun2 wrote: > > Hi, > > I have created a pdf document using the Graphics2D that displays element > in a > table. Now, for the elements within table, I want to make them hyperlinks > that > will launch HTML pages. Problem is I cannot figure out how I can pass the > URL > information to iText as I am passing the graphics2D object? > > Following is a sample code: > --------------------------------------- > Document doc = new Document(pageSize); > PdfWriter writer = PdfWriter.getInstance(doc, out); > doc.open(); > PdfContentByte cb = writer.getDirectContent(); > > // > for( int i = 0; i < numberOfPages; i++ ) > { > //PDFPage page = doc.appendNewPage( width, height ); > doc.newPage(); > PdfTemplate tp = cb.createTemplate(width, height); > Graphics2D g2D = tp.createGraphics(width, height, new > DefaultFontMapper()); > > printableObject.print( g2D, pageFormat, i ); > cb.addTemplate(tp, 0, 0); > } > doc.close(); > ----------------------- > > Is there any way I can pass the URL information so that iText can create > the > table elements with hyperlinks? > > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the > world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > iText-questions mailing list > iText-questions@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/itext-questions > > Buy the iText book: http://www.1t3xt.com/docs/book.php > > -- View this message in context: http://www.nabble.com/Create-text-URL%27s-within-document-created-using-Graphics2D-tp19042664p19055618.html Sent from the iText - General mailing list archive at Nabble.com. ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://www.1t3xt.com/docs/book.php