Quoting Paul Warren <[EMAIL PROTECTED]>: > I am current creating PDF documents using absolute positioning of text > and graphics, as described in chapter 10. > > I'm a little confused about how to start a new page, and how to get the > current page number. At the moment I am calling: > > document.newPage(); > > which works, but only if something was actually written to the previous > page. This is not a great problem, but is there anyway to force a new > page?
Just add something (preferrable something that doesn't show up when you print it) to the page. > Is there a way to get the current page number? document.getPageNumber() > always returns 0. You have to ask the (Pdf)Writer for the pagenumber, not the Document-object. This is logical if you think about it: several writer can listen to one and the same document. There is no way a document can know which pagenumber (of which writer) you need. Best regards, Bruno _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm _______________________________________________ iText-questions mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/itext-questions
