Last post Apr 26, 2013 11:55 AM by JLiles
Apr 16, 2009 04:13 PM|pcfaguiar|LINK
I've downloaded the lastest version of the ABCPdf component and it was easy to generate my first pdf file however I would like to be able to add margins to the page, like 3cm top, 2 cm right, 3cm bottom and 2cm left. I just can't seem to find that property,
I tried a few settings and it completely screws up the page, can you guys help me?
Thanks a lot
ABCPdf PDF Page Margin
May 15, 2009 01:28 PM|mark4asp|LINK
I can't tell you how to do that right now but I can advise you against using it. My version of ABCpdf.NET keeps on spontaneously uninstalling itself. The fix is to reenter the license key. Doing that means I have to restart a production server. I would never
have used it if I knew that beforehand.
Jan 29, 2010 06:50 PM|mikeinsf|LINK
Been using ABCPdf for several years now, never with your problem. You want problems? Try using ActivePDF. Never wanted to trash a piece of software so badly in my life.
Apr 26, 2013 11:55 AM|JLiles|LINK
I know this is an old thread, but it came up very high in the Google results when I searched for this topic.
The short answer is to use Doc.Rect.Inset:
Doc doc = new Doc();
this will inset the drawing rectangle by the given distance vertically and horizontally, and will apply to any pages added to the document after the inset is set. After the Inset() is called, Rect.Position can be used to move the origin point of the rectangle
to allow it to be moved from the page center.