Hi, I have a problem with aspose.Pdf and reading the number of pages of a large document.
By reading a password protected file (without specifying the password), the file is locked during deletion.
This does not happen with small files.
I attach a solution (net fw 4.8 vs2022):
The “CreateBigPdf” project creates a file of approximately 250MB.
this file can be used in the “GetPageNum” project (replace the path of the variable “String pdfPath =”)
Another test that can be done is to create a pdf with a single page (CreateBigPdf.Main for (int i = 0; i < 2; i++))
The file will be deleted correctly.
AsposePdfExample.zip (1.4 MB)