Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set Printer To Name in Vista
Message
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de rapports & Rapports
Titre:
Set Printer To Name in Vista
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Divers
Thread ID:
01291635
Message ID:
01291635
Vues:
64
I'm trying to get Amyuni PDF Converter to work in Vista.
The problem is with the SET PRINTER TO NAME command.

This code works in XP.

*********
this.opdf = CREATEOBJECT('cdintfex.cdintfex')

lnHandle = this.opdf.driverinit('SWI PDF Printer')
llReturn = this.opdf.enablePrinter(this.licensedto,this.activationcode)

set printer to name ('SWI PDF PRINTER')

lcOutputFile = ALLTRIM(thisform.cntgetfile1.eDTPATH.Value)
thisform.opdf.filenameoptions = noprompte+usefilename
thisform.opdf.defaultfilename = lcOutputFile
report form (thisform.cReportname) noeject noconsole to printer
thisform.opdf.filenameoptions = 0
**********

When I run the code in Vista, it still prints to the default printer.
If I set the Default printer to the SWI PDF Printer before running the application, it works.

I don't really want to switch the default printer for all of windows, just for this application.

Is there something special you need to do to switch the printer when running under Vista?

-Phil Sherwood
Phil Sherwood
SherWare, Inc.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform