Note that there are some explanatory texts on larger screens.

plurals
  1. POHow much file size can iTextPDF can read?
    primarykey
    data
    text
    <p>I am having <strong>Force Close</strong> in my application, when i choose a file1(size: 33,016,510 - not sure if byte or kb) but when i try a file2(size: 604,612) it does not force close. <strong>How much file size can iTextPDF can read?</strong></p> <p>file1: 400-500pages, Has Image Background and Images, but Text are all <strong>HIGHLIGHTABLE</strong> so meaning text can be READ(This is how I determine if the contents of PDF are text or images, Correct me if i am wrong).</p> <p>file2: 30-50pages, has images and no background.</p> <p>I have ideas why it force closes.</p> <ol> <li>Because of the PDF file size.</li> <li>The Code it self.</li> <li>The contents of the PDF.</li> </ol> <p>The code i use to read PDF:</p> <pre><code>page_Content = PdfTextExtractor.getTextFromPage( reader, 0, new SimpleTextExtractionStrategy()); </code></pre> <p><strong>What's the problem here?</strong> </p> <p>Comment below if the information is lacking.</p> <p>Exception:</p> <pre><code>12-26 19:20:19.026: E/AndroidRuntime(1119): FATAL EXCEPTION: main 12-26 19:20:19.026: E/AndroidRuntime(1119): java.lang.OutOfMemoryError 12-26 19:20:19.026: E/AndroidRuntime(1119): at java.util.ArrayList.add(ArrayList.java:123) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfArray.add(PdfArray.java:269) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.readArray(PdfReader.java:1608) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.readPRObject(PdfReader.java:1657) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.readDictionary(PdfReader.java:1588) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.readPRObject(PdfReader.java:1624) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.readDocObj(PdfReader.java:1143) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.readPdf(PdfReader.java:511) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.&lt;init&gt;(PdfReader.java:170) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.itextpdf.text.pdf.PdfReader.&lt;init&gt;(PdfReader.java:159) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.example.panalyzerdemo.InformationRetrieval.pdfFilePath(InformationRetrieval.java:54) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.example.panalyzerdemo.MainActivity.onActivityResult(MainActivity.java:207) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.app.Activity.dispatchActivityResult(Activity.java:3890) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.app.ActivityThread.deliverResults(ActivityThread.java:3514) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.app.ActivityThread.handleSendResult(ActivityThread.java:3560) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.app.ActivityThread.access$2800(ActivityThread.java:128) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2066) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.os.Handler.dispatchMessage(Handler.java:99) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.os.Looper.loop(Looper.java:123) 12-26 19:20:19.026: E/AndroidRuntime(1119): at android.app.ActivityThread.main(ActivityThread.java:4644) 12-26 19:20:19.026: E/AndroidRuntime(1119): at java.lang.reflect.Method.invokeNative(Native Method) 12-26 19:20:19.026: E/AndroidRuntime(1119): at java.lang.reflect.Method.invoke(Method.java:521) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:878) 12-26 19:20:19.026: E/AndroidRuntime(1119): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636) 12-26 19:20:19.026: E/AndroidRuntime(1119): at dalvik.system.NativeStart.main(Native Method) </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload