We are using gofpdf to write multiple images to PDF but we would like to also be able to write other pdfs into it (append it to the document or merge it). We have a base64 of the pdf files to merge.
We can't seem to find how to do it in the docs or if it's even possible. Does anyone know how?
I tried to use RawWriteBuf or RawWriteStr using the base64, but neither seem to work.
Related
I'm trying to extract JS from PDF files as a requirement of safe upload. Using pdfcpu I can extract pdf's objects by index, but one of the problems is that we're receiving bytes, is there a way to work with that instead of having to write it into a file on disk?
Also, does pdfcpu provides a way for extracting JS in a more declarative manner, instead of having to loop over each object?
I already did a lot of research and realized that clear information about "How to generate PDF/A-1a" or "...convert to PDF/A-1a" is really rare. I found some information to convert to PDF/A-1a via GhostScript, but I didn't make it to get it working. So, maybe there are some necessary conditions for the data missing in the first place. Conditions like propper metadata of the PDF, structured data for readability by a screen reader, alternative text for pictures, and a declaration of the given language of the text. I need a proper working GhostScript command with the corresponding gs version and the mandatory file conditions to generate or even convert to PDF/A-1a. PDF/A-1b means nothing to me because I'm already able to convert to that.
Thanks for any help.
I have had no luck figuring out how to insert an image (a gif in this case) created in perl with GD directly into an excel workbook, without first saving the image to a file. Is this possible using win32::OLE or one of the perl spreadsheet modules, or is there another trick I'm missing?
What I've tried:
searching google, stackoverflow, perlmonks
modules:
- spreadsheet::writeexcel
- excel::writer::xlsx
win32::OLE
- Pictures->Insert
- Shapes->AddPicture
All require a file as input; there was ONE (rejected) bug/patch to spreadsheet::writeexcel to allow inline images, but it didn't quite work and I'm disinclined to use non-baseline modules... any ideas?
Neither Spreadsheet::WriteExcel or Excel::Write::XLSX support adding images from anything other than a file.
I would suggest creating the images as temporary files, inserting them into a worksheet with Excel::Writer::XLSX (which has better image handling) and then removing the temporary files.
I am aiming to combine multiple PDF files each with identical dimensions into one file.
I've seen how it is done with CGPDFContext. I am just curious if there are (better?) alternatives to this method on the Mac.
Let's say I have the option to use PDFs, TIFF, PNG or JPEG files as input. Would using a different input file type mean anything significant for the process, or it would be easier to go with PDF input?
I have use PDFDocument API and it is programmatically easier to use. It may need PDF files as input though.
Is it possible to include an existing pdf file in a JasperReport?
We really want to append new data to an existing report with out regenerating the existing report. We will be exporting back to pdf. I'm looking at using iText's PdfCopy to merge two pdfs, but was hoping JasperReports might have an easier way...
I don't think you could do that in JasperReports, but it would be fairly simple in iText.
Generate the JasperReport, and then use PdfCopy to append the new report to the original (or vice-versa).