[EMAIL PROTECTED] wrote: > Hi, > > Sorry, if i may be sending this mail again.
What makes you think the negative answer will be different if you post the question twice? > In my application, the requirement is: I need to take an existing document, OK. > add some more content and change the margins, if necessary. You can add some more content at absolute positions, you can change the media box, crop box and other page boundaries, but that may not be sufficient for your needs. > (This is becoz, the PDF should be printed on a page. If you change page boundaries, you're changing the page size. Is that acceptable when printing??? > And, if the document is not printed correctly, the user will > be given a facility to change the margins a bit, so that it > can be printed correctly) As Leonard already explained (and he's Adobe's PDF Technical Standards Evangelist, so he knows), the concept of margins doesn't exist in PDF. > There is facilty in iTEXT to set the margins using document.setMargins() > method. Forget about that, it's irrelevant for you. setMargins is for newly created documents, not for existing ones. > But, how can we change the margins for an existing PDF document? By changing the MediaBox, CropBox,... > Or is there a way to create a new document, set margins for it > and add the content from existing document? Yes and no. You can import pages from existing documents, but you do know that PDF is not a format for editing, don't you? Depending on your source documents, it can be something that is very hard to impossible to achieve. > Please help me with some idea or code. Please try understanding the answers first. -- This answer is provided by 1T3XT BVBA ------------------------------------------------------------------------- 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 [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/
