Convert excel spreadsheet to PDF using VBA

I have a spreadsheet where i want to save 2 of the X numer of tabs to PDF using VBA. I have Adoboe acrobat 7 installed so to do it manually i just select the sheets and hit the "convert to Adobe PDF" button
dsvinceAsked:
Who is Participating?
 
DolGuldurCommented:
If you redo the macro but instead of using Adobe Macro to convert, go to File -> Print -> Adobe PDF, does it work?
0
 
oceanbeachCommented:
have you tried using excel's macro recorder?

tools --> macro --> record new macro.
0
 
dsvinceAuthor Commented:
Thanks had already tried that but the "Convert to Adobe PDf" did not register in the VBA code. So I need some actual code.
0
Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 
dsvinceAuthor Commented:
Thanks, So simple yet so effective, just didnt think to do it that way
0
 
dsvinceAuthor Commented:
just for the record the VBA

Application.ActivePrinter = "Adobe PDF on Ne00:"
    ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _
        "Adobe PDF on Ne00:", Collate:=True
0
 
DolGuldurCommented:
Glad I could help!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.