Re: Print file name
- From: Lee Peedin <lpeedinREMOVE@xxxxxxxxxxxxxxxxxx>
- Date: Thu, 08 Dec 2005 22:47:51 GMT
On Thu, 8 Dec 2005 10:17:02 -0800, Dan <Dan@xxxxxxxxxxxxxxxxxxxxxxxxx>
wrote:
>No, I'm not trying to suppress the Adobe PDF dialog box. I just want the file
>name that it fills in when it first displays to be a file name that I
>specify, not the generic application name. The suggestion to temporarily
>redefine App.Title works fine for me.
>
>The only additional thing that I could wish is that it would also navigate
>to the folder that is specified in App.Title, but maybe that's asking too
>much.
>
>Dan
>
Dan,
I don't know of any way to "dynamically change" the destination of the
PDF - of course you can configure a PDF port for Adobe and specify a
destination, but I know of no way to change that in code. To overcome
this, I use a combination of programming code and WMI to monitor the
print queue. After defining a name for the document, I sent the first
line to be printed. I then use WMI to monitor the print queue until
the document appears (almost instant). I then complete the printing
of the document and send the EndDoc. At that time I again suspend my
program and use WMI to monitor the print queue until the document has
left the queue. Once it has left (finished rendering), I can then use
whatever method to move or copy the file to another location. Of
course having a unique name for the document (app.title) is the only
way to make this work.
Lee
>"Lee Peedin" wrote:
>
>> Jeff,
>> If you're referring to the dialog that (by default) comes up when
>> printing to Adobe PDF, you can, in fact, completely bypass it. I have
>> this documented somewhere and will be glad to dig it up if that's what
>> you're referring to. Our company creates hundreds of PDF files weekly
>> through automation; which would be impossible if the Adobe dialog
>> couldn't be supressed.
>>
>> Lee
>>
>> On Thu, 8 Dec 2005 10:06:43 -0500, "Jeff Johnson [MVP: VB]"
>> <i.get@xxxxxxxxxxx> wrote:
>>
>> >
>> >"Dan" <Dan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
>> >news:7C43AE46-B758-4ED7-8C63-18467B6CBC17@xxxxxxxxxxxxxxxx
>> >
>> >> At times I want to print from a VB program to a printer (such as Adobe
>> >> PDF)
>> >> that prints to a file. How do I set the default file name? It always comes
>> >> up
>> >> with my program name and ".pdf" as the file name.
>> >
>> >"Comes up" where? In a dialog box that you have to click OK on to actually
>> >cause the file to print? And are you looking to bypass that dialog? Because
>> >if so, the question's been asked before and I've NEVER seen a solution.
>> >
>>
>>
.
- Follow-Ups:
- Re: Print file name
- From: NickHK
- Re: Print file name
- References:
- Re: Print file name
- From: Jeff Johnson [MVP: VB]
- Re: Print file name
- From: Lee Peedin
- Re: Print file name
- Prev by Date: Re: Loading a form with code
- Next by Date: Re: Run-time Max & Min Buttons?
- Previous by thread: Re: Print file name
- Next by thread: Re: Print file name
- Index(es):
Relevant Pages
|