1

I currently have a program that can take a pdf saved to an android device and calls an intent to display the pdf. What I wish to do is to create a multipage pdf out of 2 pdf files saved to the device. Is there some sort of token or symbol that pdfs look for that tells the displayer to create a new page? What can I put between the two inputstreams to denote the fact that I want a new pdf page?

I did a lot of research and tried to use itext but it seemed to over-complicate my program. Is there a simple way to achieve my goal?

Thanks in advance!

user821863
  • 479
  • 5
  • 15
  • You thought itext over complicates your program, but actually you seem to underestimate the complexity of PDF. There is no simple concatenation of two pdfs with some joining Byte sequence. Instead The objects in the pdfs have to be merged, meta-information have to be brought together, etc. So, what have you tried with itext? And furthermore, is there anything special about your source PDFs? As your application crashes when using PDFBox for merging, there seems something odd. – mkl Jun 23 '13 at 21:18
  • Thanks for your input @mkl - I just commented on Dalmas' post below. Neither PDFBox nor iText will work on Android. Look at what CommonsWare answered [to this post on SO](http://stackoverflow.com/questions/10536332/android-jre-system-libary-java-awt-is-missed). That is the problem that I have now discovered which has been driving me crazy for the last 6 hours. Do you know of any other software that can merge 2 pdfs on android? – user821863 Jun 23 '13 at 21:54
  • 1
    Unfortunately Dalmas' post seems to be gone, so I cannot see your comment there. Concerning itext and Android, though, there is a special edition of the current itext for Android and the Google App Engine, cf. http://itextsupport.com/download/android.html – mkl Jun 24 '13 at 04:08

0 Answers0