Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can VFP app have its own copy of Word?
Message
 
À
16/02/2012 11:22:24
Mike Yearwood
Toronto, Ontario, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Desktop
Divers
Thread ID:
01532736
Message ID:
01535609
Vues:
60
Thanks Mike. I'll look into that, although around 11 pm last night I realized the problem is more complex than I'd thought. The app really needs its own 'default printer' for use with both VFP and Word. The problem is that there are multiple types of devices in the list returned by Aprinters() and most can't print to paper and there doesn't seem to be an easy way to tell which ones can!

Update: 5 pm: The printer list turns out to be do-able, and you were very close with 88. That is wdFilePrint; 97 is wdDialogFilePrint and it does offer the option DoNotSetAsSysDefault. If you use GetPrinter() the dialog displays but substituting the printer name allows it to run "silent".
WITH oWord.Dialogs(wdDialogFilePrintSetup)	&& wdDialogFilePrintSetup =97
    .Printer=AppDefaultPrinter			&& getprinter() shows the dialog; printer name runs 'silent'
    .DoNotSetAsSysDefault = .t.
    .execute()
ENDWITH
That's exactly what I was looking for. Thanks!
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform