Hi guys I am an absolute beginner so go easy on me, why is this not working for me, I really do not understand why this is not working, but I am a beginner so if someone could correct this for me, I would really appreciate it. I am surprised that it does not work My Error messege: Answer iText
Tag: itext
number of page of document in Java
I have the base64 and the byte[] of a pdf document, and I need to obtain from this number of page of the document how I could do it. Answer Your question is not quite clear. What do you mean that you have the base64 encoded byte[]? Normally you either have a base64 encoded string or an byte[].
iText Border.getWidth()’ on a null object reference
I’m Using iText to create a PDF in an android app which is running on an android 7 device. My input is a xml-file with some information which is displayed on the pdf. In some constellation of the xml-content I’m getting the following exception: I’m not able to recreate this Error in my IDE, the exact same xml is running
Save text pdf direct to s3 without having to save it locally
I am generating pdf files using itext 5 and Java, and saving them locally then saving these local saved files on AWS S3. Is there a way to just send them straight to S3 without having to save them locally. I have seen a few examples but none is working for me. This is how am generating the pdf file
Merge encrypted pdf file programmatically exception
I have been using the following code to merge encrypted pdf files programmatically. I started getting this error recently upon trying to create the pdfReader at this line of code: com.itextpdf.text.exceptions.InvalidPdfException: Unknown encryption type R = 6 at com.itextpdf.text.pdf.PdfReader.readPdf(PdfReader.java:738) at com.itextpdf.text.pdf.PdfReader.(PdfReader.java:181) at com.itextpdf.text.pdf.PdfReader.(PdfReader.java:219) at com.itextpdf.text.pdf.PdfReader.(PdfReader.java:207) at com.project.mainPageShop.mergeMyFiles(mainPageShop.java:4368) at com.project.mainPageShop$DownloadFileAsync.onPostExecute(mainPageShop.java:11757) at com.project.mainPageShop$DownloadFileAsync.onPostExecute(mainPageShop.java:11628) at android.os.AsyncTask.finish(AsyncTask.java:755) at android.os.AsyncTask.access$900(AsyncTask.java:192) at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:772) at android.os.Handler.dispatchMessage(Handler.java:107) at
Remove FixedLeading at the first line on each page
I want to remove setFixedLeading at the first line on each page (100+) I read a bit text(more 100 page with help while). And I set padding and margin to 0 but I still have top indent. Why? Help me pls? How delete it? PDF file: https://pdfhost.io/v/Byt9LHJcy_PDFpdf.pdf Answer At the time of element creation you don’t know the page it
Why is the Digital Signature not visible in some PDF documents using iText 7.1.11?
My project digitally signs PDF documents using a digital certificate and displays the signature at the bottom left of the document. It had always worked well until now, there are some documents that are digitally signed but it is not shown although it is recognized that the rectangle where it is visible is. Could someone help with this, I leave
Java iText scale document to A4
I have the following method that “resizes” all the pages of a document to A4 page dimensions: However , this is not working as expected , the pages are being transformed to A4 (297×210) BUT the content is not being fitted inside (scaled) , the content appears cutted because the original pages are larger than 297X210 . How can I
Is there any way to keep whitespaces before text in iText7?
I’ve added a Text object that start with whitespaces to the Paragraph object, but the whitespace of paragraph is removed in iText7(7.0.4). It looks like left trim. Is this a specification of Paragraph? Is there any way to keep whitespaces before text? Answer iText will trim spaces. But it will not remove non-breaking spaces.
How to add border to paragraph in itext pdf library in java?
I have created a paragraph in using itext pdf library in java. I have to add border to paragraph, not to the whole document. How to do it ? Answer Please take a look at the BorderForParagraph example. It shows how to add a border for a paragraph like this: There is no method that allows you to create a