Concatenate Two PDF Files in VB.NET?

Hi Experts,

Not sure if this is possible, but here goes - I need to be able to join two PDF files together programatically. Operating system is XP, so I am looking to maybe create a command line app using VB.NET and pass in the two filenames as switches. This app I then need to call from a script.

Is this possible using VB.NET? I am open to suggestions, but I do need this to be done via program control, with no UI. I have googled this but I'm not getting very far.

Any ideas?
LVL 1
gczAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

MitzsCommented:
I dont kow whether you are ready to user 3rd pary controls. If yes then here is one example of it with code.
http://www.aspose.com/documentation/file-format-components/aspose.pdf.kit-for-.net-and-java/concatenate-pdf-documents.html
 
iText is a library that allows you to generate PDF files on the fly and its free
http://www.lowagie.com/iText/ 
 
0
gczAuthor Commented:
Thanks for the post.

I have done some further digging around and found a utility called pdftk, which is basically what I was hoping to end up with myself. It is a command line utility which can append pdfs among other things, and is going to be lot quicker than coding something myself:

http://www.accesspdf.com/pdftk/

Pass in the filenames, and the output filename and it does it for you, example:

'pdftk.exe pdf1.pdf pdf2.pdf cat output output.pdf'

This appends pdf1.pdf and pdf2.pdf and outputs them as output.pdf.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.