for (int k = 1; k <= reader.getNumberOfPages(); ++k) { PdfContentByte under = stamp.getUnderContent(k); under.addImage(img); }
----- Original Message ----- From: "Krishna Kishore .J" <[EMAIL PROTECTED]> To: <itext-questions@lists.sourceforge.net> Sent: Wednesday, August 03, 2005 2:32 PM Subject: [iText-questions] Adding an Image on all pages in the pdf > Hi All, > > Is there a way to add an image on all the pages in a pdf. > > I have a pdf with 3 pages as input. I need to read this pdf then populate > the form fields and then put an image on all the three pages. > I am using the following code: > > File fImg = new File(filePath); > img = Image.getInstance(fImg.toURL()); > img.setAbsolutePosition(110, 160); > PdfContentByte under = stamp.getUnderContent(1); > PdfWriter writer = stamp.getWriter(); > under.addImage(img); > > This is adding image on the first page and not on all the three pages. > > Is there any way to resolve this. > > Kindly request for your valuable inputs. > > Thanks in advance. > Krishna Kishore > > > > ------------------------------------------------------- > SF.Net email is sponsored by: Discover Easy Linux Migration Strategies > from IBM. Find simple to follow Roadmaps, straightforward articles, > informative Webcasts and more! Get everything you need to get up to > speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click > _______________________________________________ > iText-questions mailing list > iText-questions@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/itext-questions ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions