Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How can I print a text file to printer without FILETOSTR
Message
 
À
22/08/2005 07:50:35
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 7
OS:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01042627
Message ID:
01042642
Vues:
21
>thank's for this tip. But I have Epson EPL 6200L USB printer and I received this message from OS:
> "this document failed to print"
>Can you help me with that?
>This class don't work with USB printer?

Andrei,

Here what works on my printer (with use of RawPrint.VCX):
cPrinter = GETPRINTER()
IF NOT EMPTY(cPrinter) && Printer selected
   LOCAL Printdev1
   SET CLASSLIB TO RawPrint.VCX
   Printdev1 = CREATEOBJECT("Printdev")
   Printdev1.cPrinterName = (m1)
   IF .NOT. Printdev1.oOpen()
      msg = "Printer is not ready!"
      IF Printdev1.nopenerror == 0
         msg = msg +" Check the SPOOLER settings"
      ELSE
         msg = msg + " Error # " +STR(Printdev1.nopenerror)
      ENDIF
      MessageBox(msg, 16, "Print error")
      RETURN
   ENDIF
   Printdev1.cFileName = YourFullPathToFile
   Printdev1.oPrintFile()
   Printdev1.oClose()
ENDIF
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform