PC Review


Reply
Thread Tools Rate Thread

How to add filename for Acrobat printout?

 
 
Gary Burton
Guest
Posts: n/a
 
      17th Aug 2007
I am using Excel 2003.

I am trying to output a print area from my spreadsheet to a PDF file, but I
can't seem to find a way to automatically or even semi-automatically specify
the filename. I generate the path and filename in Excel.

I tried the PrintToFile option of the Printout method, but it wound up
prompting me to disable a font feature in Acrobat. I got cold feet at that
point because of the sensitivity to changing settings in my work
environment. I'm not sure PrintToFile would get me PDF anyway.

Since I couldn't find a way to automatically enter the filename, the
intention now is to use copy and paste when the Acrobat printer prompts for
a filename. I copy the range that includes the filename, and then start my
VBA routine. VBA opens up the Acrobat printer and prompts for a filename,
but the paste command is grayed out. I can paste it into a Word document,
but not into the filename box for the Acrobat printer.

Suggestions?


--
Gary Burton


 
Reply With Quote
 
 
 
 
Michael Bednarek
Guest
Posts: n/a
 
      17th Aug 2007
On Thu, 16 Aug 2007 19:07:45 -0700, Gary Burton wrote in
microsoft.public.excel:

>I am using Excel 2003.
>
>I am trying to output a print area from my spreadsheet to a PDF file, but I
>can't seem to find a way to automatically or even semi-automatically specify
>the filename. I generate the path and filename in Excel.
>
>I tried the PrintToFile option of the Printout method, but it wound up
>prompting me to disable a font feature in Acrobat. I got cold feet at that
>point because of the sensitivity to changing settings in my work
>environment. I'm not sure PrintToFile would get me PDF anyway.
>
>Since I couldn't find a way to automatically enter the filename, the
>intention now is to use copy and paste when the Acrobat printer prompts for
>a filename. I copy the range that includes the filename, and then start my
>VBA routine. VBA opens up the Acrobat printer and prompts for a filename,
>but the paste command is grayed out. I can paste it into a Word document,
>but not into the filename box for the Acrobat printer.
>
>Suggestions?


I suggest you use the PDFDistiller object (from the "Acrobat Distiller"
library (ACRODIST.EXE)) and its FileToPDF method. Some details at the
links in
<http://groups.google.com.au/group/comp.text.pdf/browse_frm/thread/36b7193f0f7e420e/2ed583c3c507e4a1?lnk=st&rnum=2&hl=en#2ed583c3c507e4a1>.

Alternatively, the free PDFCreator also provides a COM/OLE interface and
its distribution provides examples in VBA. It's what I use now.

--
Michael Bednarek http://mbednarek.com/ "POST NO BILLS"
 
Reply With Quote
 
Gary Burton
Guest
Posts: n/a
 
      24th Aug 2007
Thanks for your response!

It isn't a practical solution in my case because I am on a highly
controlled network and can't change either the software or the setting.

I found a way to print to a textbox, then copy from the textbox before I
launch the output routine. then I can patch the filename in.


"Michael Bednarek" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> On Thu, 16 Aug 2007 19:07:45 -0700, Gary Burton wrote in
> microsoft.public.excel:
>
>>I am using Excel 2003.
>>
>>I am trying to output a print area from my spreadsheet to a PDF file, but
>>I
>>can't seem to find a way to automatically or even semi-automatically
>>specify
>>the filename. I generate the path and filename in Excel.
>>
>>I tried the PrintToFile option of the Printout method, but it wound up
>>prompting me to disable a font feature in Acrobat. I got cold feet at that
>>point because of the sensitivity to changing settings in my work
>>environment. I'm not sure PrintToFile would get me PDF anyway.
>>
>>Since I couldn't find a way to automatically enter the filename, the
>>intention now is to use copy and paste when the Acrobat printer prompts
>>for
>>a filename. I copy the range that includes the filename, and then start my
>>VBA routine. VBA opens up the Acrobat printer and prompts for a filename,
>>but the paste command is grayed out. I can paste it into a Word document,
>>but not into the filename box for the Acrobat printer.
>>
>>Suggestions?

>
> I suggest you use the PDFDistiller object (from the "Acrobat Distiller"
> library (ACRODIST.EXE)) and its FileToPDF method. Some details at the
> links in
> <http://groups.google.com.au/group/comp.text.pdf/browse_frm/thread/36b7193f0f7e420e/2ed583c3c507e4a1?lnk=st&rnum=2&hl=en#2ed583c3c507e4a1>.
>
> Alternatively, the free PDFCreator also provides a COM/OLE interface and
> its distribution provides examples in VBA. It's what I use now.
>
> --
> Michael Bednarek http://mbednarek.com/ "POST NO BILLS"



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
HttpPostedFile.saveas(filename) issue when the filename is used "-" as a part of the filename. Ken Microsoft Dot NET Framework 0 25th Feb 2009 10:58 PM
Re: PDF Filename for Acrobat Alex Dybenko Microsoft Access VBA Modules 0 20th Jan 2007 09:13 AM
Is there a Filename property in PrintOut property Christian Microsoft Excel Programming 4 3rd Sep 2004 10:12 PM
PrintOut with Adobe Acrobat 6.0 Tom Microsoft Excel Programming 1 16th Jan 2004 06:33 PM
Acrobat PDFWriter vs Acrobat Distiller for Access reports M Skabialka Microsoft Access Reports 2 26th Sep 2003 03:53 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:44 PM.