Solved

Excel to PDF converter (using VBA)

Posted on 2007-03-18
4
972 Views
Last Modified: 2009-12-16
I would like to create a PDF from Excel VBA.
a)The PDF should have same colors as the charts in the original excel and
b) should also retain the hyper links in the original excel
0
Comment
Question by:SVKUNTE
4 Comments
 
LVL 45

Accepted Solution

by:
patrickab earned 250 total points
ID: 18747187
SVKUNTE,

VBA does not contain an Excel to PDF converter. You perhaps could invoke an Excel to PDF converter from a VBA routine but that's about all you can do. If VBA did contain such a facility there would be no need for stand-alone PDF applications such as 'EzeePDF' and many others around. You can get a free copy of 'EzeePDF' from:

http://www.softpedia.com/get/Office-tools/PDF/Simple-PDF-Editor-Pro.shtml

Hope that helps

Patrick
0
 
LVL 1

Expert Comment

by:MWNZ
ID: 19428625
There are free PDF printing solutions out there using, e.g. Ghostscript.  Once you have created a pdf printer, you would simply issue the print command from within your VBA and point it to the pdf printer.  See http://pad.olsonnetwork.com/faqs/MakePDF_HOWTO_Images.html
I am using a redmon/ghoscript GPL 8.56 combination and confirm that hyperlinks are clickable in the resultant pdf and the resultant file is in colour (same as in the original excel sheet).  I did not need to use the PDFWriter application as I use the in-built pdfwriter device in ghostscript.  I also installed the adobe postscript drivers and used the distiller ppd file (available from adobe).
0
 
LVL 1

Expert Comment

by:Computer101
ID: 20294398
Forced accept.

Computer101
EE Admin
0

Featured Post

Do email signature updates give you a headache?

Are you constantly making changes to email signatures? Are the images not formatting how you want them to? Want high-quality HTML signatures on all devices, including on mobiles and Macs? Then, let Exclaimer solve all your email signature problems today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A Bare Metal Image backup allows for the restore of an entire system to a similar or dissimilar hardware. They are highly useful for migrations and disaster recovery. Bare Metal Image backups support Full and Incremental backups. Differential backup…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now