Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Fox printer not really the printer
Message
De
19/12/2007 09:30:39
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
MS SQL Server
Divers
Thread ID:
01276259
Message ID:
01276585
Vues:
24
>>>>Hi All,
>>>>
>>>>Still trying to fix my ps2pdf problem.
>>>>
>>>>I believe that I have tracked it down to the command:
>>>>
>>>>REPORT FORM (lcreportfilename) NOCONSOLE TO FILE (lcReportName)
>>>>
>>>>
>>>>I have the command:
>>>>
>>>>set("PRINTER", 3)
>>>>
>>>>
>>>>in the debug window, so that I can see which printer is selected at the time of execution. It shows the correct printer/driver selected. But, if my default printer/driver is not the postscript driver, my program is suppose to change to a postscript driver or give an error that no printer/driver is loaded on the machine.
>>>>
>>>>When the default printer is set to a postscript driver - the .ps file is correct.
>>>>When the default printer is set to a non-postscript driver - the .ps file is not correct.
>>>>
>>>>Any ideas?
>>>
>>>Are you changing the default printer in your program, or "program is suppose to change to a postscript driver", and your question is how to do it?
>>
>>Sorry, did not mean to be unclear there. My program finds the correct printer/driver and runs:
>>
>>SET PRINTER TO NAME (gaPrinters(lnPos,1))
>>
>
>I believe, you need to change the Windows default printer, like:
>
>oWSHNet = CREATEOBJECT('Wscript.Network')
>oWSHNet.SetDefaultPrinter('WindowsPrinterName')

This is what I ended up using to fix the problem, but my question is why is vfp not using the correct printdriver in report form < reportname > like it is suppose to. And did in all versions before vfp9?

Thanks for the help, Yuri
Beth
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform