Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
Hi
I have an excel sheet which i would like to convert to pdf via vb automatic code. What i want to do is click a button - run a macro that would convert the sheet to PDF. I recorded a macro when doing this manually, but when i run the code i cannot get passed the save as dialog box. Is there any code to do this? Thanks in advance Paul |
#2
![]() |
|||
|
|||
![]()
Paul Watkins wrote:
Hi I have an excel sheet which i would like to convert to pdf via vb automatic code. What i want to do is click a button - run a macro that would convert the sheet to PDF. I recorded a macro when doing this manually, but when i run the code i cannot get passed the save as dialog box. Is there any code to do this? Thanks in advance Paul ------------------------------ I'm not sure what you want to do, but what I have done is to install PDF995. It's a free program on the web that acts like a printer driver. You tell Excel (or any other program) to print what you want, and then select PDF995 as the printer to send it to and it creates a PDF file that's an image of what you selected to print. Bill |
#3
![]() |
|||
|
|||
![]()
Sorry i was not clear.
I have PDF995 installed, what i want to do is the automate this process via VB code. without having to fill in the save as dialog box. Paul "Bill Martin -- (Remove NOSPAM from address)" wrote in message ... Paul Watkins wrote: Hi I have an excel sheet which i would like to convert to pdf via vb automatic code. What i want to do is click a button - run a macro that would convert the sheet to PDF. I recorded a macro when doing this manually, but when i run the code i cannot get passed the save as dialog box. Is there any code to do this? Thanks in advance Paul ------------------------------ I'm not sure what you want to do, but what I have done is to install PDF995. It's a free program on the web that acts like a printer driver. You tell Excel (or any other program) to print what you want, and then select PDF995 as the printer to send it to and it creates a PDF file that's an image of what you selected to print. Bill |
#4
![]() |
|||
|
|||
![]()
Paul Watkins wrote:
Sorry i was not clear. I have PDF995 installed, what i want to do is the automate this process via VB code. without having to fill in the save as dialog box. Paul Sorry, but I wouldn't know how to do that. It seems that you want to run VB from Excel to control part of the OS. That's probably entirely doable, but not by *me* <g. Bill |
#5
![]() |
|||
|
|||
![]()
Hi Paul,
I'm going through a similar dilema myself. I've created a macro that does pretty much what you're talking about, but the created file is either empty (0 KB) or corrupted and won't open using Adobe. !?!?! Ugh. This is some of the VB I used: Application.ActivePrinter = "Adobe PDF on Ne00:" For CoNo = 7 To 400 AppStr = "LoadCompany_" & CoNo CellRefA = "A" & CoNo CellRefB = "B" & CoNo CoName = Range(CellRefB).Value XStr = UCase(Range(CellRefA).Value) If XStr = "X" Then Application.Run AppStr Sheets("SUMMARY").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True, PrToFileName:="C:\Documents and Settings\marusichd\Desktop\Email Worksheets\" & CoName & ".pdf" Sheets("FLEET").Select ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True, PrToFileName:="C:\Documents and Settings\marusichd\Desktop\Email Worksheets\" & CoName & "2.pdf" Sheets("SELECT TO PRINT").Select End If Next CoNo If you try this with PDF995 and find it works, let me know. I'm using Excel XP and Adobe Acrobat 6.0 Thanx, Darcy :o) "Bill Martin -- (Remove NOSPAM from addre" wrote: Paul Watkins wrote: Sorry i was not clear. I have PDF995 installed, what i want to do is the automate this process via VB code. without having to fill in the save as dialog box. Paul Sorry, but I wouldn't know how to do that. It seems that you want to run VB from Excel to control part of the OS. That's probably entirely doable, but not by *me* <g. Bill |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel 2003 FAILS, but Excel 2000 SUCCEEDS ??? | Excel Discussion (Misc queries) | |||
conversion of MS Works Spreadsheet to Excel 2002 Spreadsheet | Excel Discussion (Misc queries) | |||
I get a program error when I download an excel template | Excel Discussion (Misc queries) | |||
Excel Time Conversion | Excel Discussion (Misc queries) | |||
Difference in number of Excel NewsGroups | Excel Discussion (Misc queries) |