Copy a region out from a page

I need to be able to “copy” a portion of a source pdf and save it as another PDF. So for instance say I want to grab rectangle 0,0,100,100 from the source pdf and create another pdf that is 100 x 100 and contains the original contents.

One possibility is to use the ElementBuilder class ( to iterate through a page, and write the elements inside the rectangle to the output file. You can also achieve this by making a copy of a page and run redaction on the new page. You can find more information about the redaction feature from the following links:

Btw. In case you do not care about information hiding, you could simply call page.SetCropBox(rect) and you are done.