Quantcast
Channel: Aspose.Pdf Product Family
Viewing all articles
Browse latest Browse all 3131

"System.OutOfMemoryException" when extracting text from Large PDF

$
0
0
Dear Team,

I'm evaluating your component related to my requirements. 

When extracting the content of PDF file which has more than 1800 pages (PDF size --> 40 MB), the system throws "System.OutOfMemoryException"

Below is the code snippet i have used to extract the PDF file.

Document pdfDocument = newDocument("input.pdf");

TextAbsorber textAbsorber = newTextAbsorber();

pdfDocument.Pages.Accept(textAbsorber);

string extractedText = textAbsorber.Text;


Please advise me if anything wrong here. 

Update on 2nd July 2013:

Same error "System.OutOfMemoryException" when trying to extract a text from PDF file with 366 pages (PDF size --> 5 MB) using multiple threads (Minumum 3 times). Attached the file for your reference

 for (int i = 0; i < 3; i++)
 {
       new Thread(new ParameterizedThreadStart(ReadPDFContentUsingAspose)).Start(filepath));
 }

Please let me know if any restrictions on the PDF size, no of pages it can extract and no of files it can process at a time.

Viewing all articles
Browse latest Browse all 3131

Trending Articles