Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 258
Default Save Excel file into PDF file............

I have a macro which save an excel file into PDF file. But, I have been
getting the window message Window PDF File as and then I have to type
manually the file name.

I would like to know if there is any VBA that can made my process
automatically.
Therefore, the file name will be create with the location at specific
directory without see the window mentioned above?

Best regards.
Maperalia

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Save Excel file into PDF file............

I think people would need to see the macro to see how you are saving the
file as PDF (what software/product//method are you using).

the answer would depend on the features offered/ behavior by the
software/product and how those features/behavior can be accessed or
controlled.

--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
I have a macro which save an excel file into PDF file. But, I have been
getting the window message "Window PDF File as" and then I have to type
manually the file name.

I would like to know if there is any VBA that can made my process
automatically.
Therefore, the file name will be create with the location at specific
directory without see the window mentioned above?

Best regards.
Maperalia



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 145
Default Save Excel file into PDF file............

Check up prtofilename parameter in printout method please.

--
Regards
PY & Associates

"Tom Ogilvy" wrote in message
...
I think people would need to see the macro to see how you are saving the
file as PDF (what software/product//method are you using).

the answer would depend on the features offered/ behavior by the
software/product and how those features/behavior can be accessed or
controlled.

--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
I have a macro which save an excel file into PDF file. But, I have been
getting the window message "Window PDF File as" and then I have to type
manually the file name.

I would like to know if there is any VBA that can made my process
automatically.
Therefore, the file name will be create with the location at specific
directory without see the window mentioned above?

Best regards.
Maperalia





  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 258
Default Save Excel file into PDF file............

Tom;
This is the macro I have been using to save an excel file. This macro is
working wonderful:
Sub SaveButton_Click()
'SAVE DATA TO FILE
Dim Boring As String
WO As String
Source As String
Depth As String
Dim sFilename As String

WO = Worksheets("Sheet1").Range("C3")
Boring = Worksheets("Sheet1").Range("C4")
Depth = Worksheets("Sheet1").Range("C5")
Source = Worksheets("Sheet1").Range("C2")

Progname = "C:\Sample\ " & WO & " S-" & Boring & "@" & Depth & " " &
Source & ".xls"
ActiveWorkbook.SaveCopyAs Progname
End Sub

In addition, I have this program that save a PDF file. However, I got the
message I mentioned in my previous e-mail. Besides, I cannot make it work as
a the macro to save an excel file:
Sub SaveAsPDF()
'Dim WO As String
'Dim Track As String
'Dim Done As Date
'Dim sFilename As String
'Dim progname As Double

'WO = Worksheets("Sheet1").Range("F2")
' Track = Worksheets("Sheet1").Range("F3")

Application.ActivePrinter = "Adobe PDF on Ne05:"
ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _
"Adobe PDF on Ne05:", Collate:=True
'progname = "C:\Sample\" & WO & "@" & Track & ".PDF"
'ActiveWorkbook.SaveCopyAs Progname
End Sub

Could you please help me with this matter?. I will reallt appreciate it.

Best regards.
Maperalia








"Tom Ogilvy" wrote:

I think people would need to see the macro to see how you are saving the
file as PDF (what software/product//method are you using).

the answer would depend on the features offered/ behavior by the
software/product and how those features/behavior can be accessed or
controlled.

--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
I have a macro which save an excel file into PDF file. But, I have been
getting the window message "Window PDF File as" and then I have to type
manually the file name.

I would like to know if there is any VBA that can made my process
automatically.
Therefore, the file name will be create with the location at specific
directory without see the window mentioned above?

Best regards.
Maperalia




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Save Excel file into PDF file............

This has been asked many times and the methods to do it can vary by version
of Adobe print driver. You can have a look here and see if you can find the
solution that works for you:

http://tinyurl.com/9hbe7

I would check out the prttofilename property as suggested by PY, but not
sure that alone will do it. The first link in the above URL talks about
making some changes to the print driver options and then using that.
--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
Tom;
This is the macro I have been using to save an excel file. This macro is
working wonderful:
Sub SaveButton_Click()
'SAVE DATA TO FILE
Dim Boring As String
WO As String
Source As String
Depth As String
Dim sFilename As String

WO = Worksheets("Sheet1").Range("C3")
Boring = Worksheets("Sheet1").Range("C4")
Depth = Worksheets("Sheet1").Range("C5")
Source = Worksheets("Sheet1").Range("C2")

Progname = "C:\Sample\ " & WO & " S-" & Boring & "@" & Depth & " " &
Source & ".xls"
ActiveWorkbook.SaveCopyAs Progname
End Sub

In addition, I have this program that save a PDF file. However, I got the
message I mentioned in my previous e-mail. Besides, I cannot make it work

as
a the macro to save an excel file:
Sub SaveAsPDF()
'Dim WO As String
'Dim Track As String
'Dim Done As Date
'Dim sFilename As String
'Dim progname As Double

'WO = Worksheets("Sheet1").Range("F2")
' Track = Worksheets("Sheet1").Range("F3")

Application.ActivePrinter = "Adobe PDF on Ne05:"
ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _
"Adobe PDF on Ne05:", Collate:=True
'progname = "C:\Sample\" & WO & "@" & Track & ".PDF"
'ActiveWorkbook.SaveCopyAs Progname
End Sub

Could you please help me with this matter?. I will reallt appreciate it.

Best regards.
Maperalia








"Tom Ogilvy" wrote:

I think people would need to see the macro to see how you are saving the
file as PDF (what software/product//method are you using).

the answer would depend on the features offered/ behavior by the
software/product and how those features/behavior can be accessed or
controlled.

--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
I have a macro which save an excel file into PDF file. But, I have

been
getting the window message "Window PDF File as" and then I have to

type
manually the file name.

I would like to know if there is any VBA that can made my process
automatically.
Therefore, the file name will be create with the location at specific
directory without see the window mentioned above?

Best regards.
Maperalia








  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 258
Default Save Excel file into PDF file............

Thanks Tom and PY.
I will check the information and advise you gave me.

Best regards.
Maperalia

"Tom Ogilvy" wrote:

This has been asked many times and the methods to do it can vary by version
of Adobe print driver. You can have a look here and see if you can find the
solution that works for you:

http://tinyurl.com/9hbe7

I would check out the prttofilename property as suggested by PY, but not
sure that alone will do it. The first link in the above URL talks about
making some changes to the print driver options and then using that.
--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
Tom;
This is the macro I have been using to save an excel file. This macro is
working wonderful:
Sub SaveButton_Click()
'SAVE DATA TO FILE
Dim Boring As String
WO As String
Source As String
Depth As String
Dim sFilename As String

WO = Worksheets("Sheet1").Range("C3")
Boring = Worksheets("Sheet1").Range("C4")
Depth = Worksheets("Sheet1").Range("C5")
Source = Worksheets("Sheet1").Range("C2")

Progname = "C:\Sample\ " & WO & " S-" & Boring & "@" & Depth & " " &
Source & ".xls"
ActiveWorkbook.SaveCopyAs Progname
End Sub

In addition, I have this program that save a PDF file. However, I got the
message I mentioned in my previous e-mail. Besides, I cannot make it work

as
a the macro to save an excel file:
Sub SaveAsPDF()
'Dim WO As String
'Dim Track As String
'Dim Done As Date
'Dim sFilename As String
'Dim progname As Double

'WO = Worksheets("Sheet1").Range("F2")
' Track = Worksheets("Sheet1").Range("F3")

Application.ActivePrinter = "Adobe PDF on Ne05:"
ActiveWindow.SelectedSheets.PrintOut Copies:=1, ActivePrinter:= _
"Adobe PDF on Ne05:", Collate:=True
'progname = "C:\Sample\" & WO & "@" & Track & ".PDF"
'ActiveWorkbook.SaveCopyAs Progname
End Sub

Could you please help me with this matter?. I will reallt appreciate it.

Best regards.
Maperalia








"Tom Ogilvy" wrote:

I think people would need to see the macro to see how you are saving the
file as PDF (what software/product//method are you using).

the answer would depend on the features offered/ behavior by the
software/product and how those features/behavior can be accessed or
controlled.

--
Regards,
Tom Ogilvy

"maperalia" wrote in message
...
I have a macro which save an excel file into PDF file. But, I have

been
getting the window message "Window PDF File as" and then I have to

type
manually the file name.

I would like to know if there is any VBA that can made my process
automatically.
Therefore, the file name will be create with the location at specific
directory without see the window mentioned above?

Best regards.
Maperalia







Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
excel 2003 file converted to .xlsm file when save to network drive Chris Excel Discussion (Misc queries) 3 January 23rd 08 02:56 PM
How do you save an excel file to be read as IBM-type text file ? Dee Franklin Excel Worksheet Functions 2 October 10th 06 02:46 AM
auto save excel file every 10 minutes to its original file name MEG Excel Discussion (Misc queries) 3 September 8th 05 07:12 PM
How can I save a file as a comma-delimited text file in Excel? LAM Excel Discussion (Misc queries) 1 May 3rd 05 10:24 PM
Excel marcos firing on file save as but not file save Andy Excel Programming 1 August 3rd 04 10:34 AM


All times are GMT +1. The time now is 06:49 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright 2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"