Information générale
Catégorie:
COM/DCOM et OLE Automation
John,
I think I have found the answer:
I just found that there is an "OutputFileName" parameter that I can pass.
I recorded a macro, looked at it, found the parameter and then tested it. It worked!
******************
Macro Routine:
Application.PrintOut FileName:="", Range:=wdPrintAllDocument, Item:= _
wdPrintDocumentContent, Copies:=1, Pages:="", PageType:=wdPrintAllPages, _
Collate:=True, Background:=True, PrintToFile:=True, OutputFileName:="test.prn", _
Append:=False
******************
I hope this helps anyone else looking for this answer!
Thanks again John!
Dave :-)
>George Tasker and I are burning up the Private messages discussing this just >now :-).
>You'd think it'd be as simple as setting Word.ActivePrinter to "PrinterDriver >on C:\Program Files\Adobe\PDF output\*.PDF" which is what ActivePrinter >returns >after you have manually set it, but it's apparently not.
>Have you tried setting the PrintToFile parm to .T. in Word.Printout()?
>Thanks for the quick response. However, I think that I ommitted the fact that >I want to be able to send the print job to a specific filename without user >intervention. Is this possible?
>
>Dave :-)
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement