We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

CropBox does not actually delete the remaining content


I am evaluating ASPOSE.PDF .NET for one of my projects. The requirement is to extract a portion of PDF and save it into a new PDF file. The new PDF will be read by another PDF processor. I am using the CropBox function to extract the required portion and save it into new PDF. When the new PDF is read by another PDF processor, it shows the whole PDF not the cropped content. So, CropBox is only putting some mark/boundary for Acrobat reader and does not actually delete the unwanted content from the PDF. Can you please advice how to crop the box and delete the remaining content from PDF. Here is the sample program:

Aspose.Pdf.Document document = new Aspose.Pdf.Document(inputFileName);
Aspose.Pdf.Document outputPDF1F = new Aspose.Pdf.Document();
outputPDF1F.Pages.Insert(1, document.Pages[1]);
Aspose.Pdf.Rectangle pageRect1F = new Aspose.Pdf.Rectangle(324, 754, 566, 610);
outputPDF1F.Pages[1].CropBox = pageRect1F;
outputPDF1F.Save(OutputFolder + getFileName(inputFileName) + “-1F.pdf”);

Hi Yasir,

Thanks for your inquiry. I've managed to reproduce the issue at my end and logged it as PDFNEWNET-35125 in our bug tracking system for further investigation and resolution. You will be notified via this thread as soon as it is resolved.

Sorry for the inconvenience faced.

Best Regards,


I am also facing the same Problem . Is this issue resolved ??


Hi Hose,

Thanks for your inquiry. I’m afraid the reported issue is still not resolved and pending for analysis in queue with other priority tasks. However, I’ve requested the development team for the update and will notify you about issue status via this forum thread as soon as I get a feedback.

Sorry for the inconvenience faced.

Best Regards,

Hi Yasir/Hose,

I am sorry for the late response. We have investigated your reported issue and would like to update you that Setting CropBox for page changes cropping box of the page and does not change page contents. This is expected behavior.

We will appreciate it if you please share some details or sample file for your intended results. So we will can investigate it further.

We are truly sorry for the inconvenience.

Best Regards,