Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Send Raw Data to a Printer
Message
De
25/09/2009 17:37:15
 
 
À
25/09/2009 16:52:34
Al Doman (En ligne)
M3 Enterprises Inc.
North Vancouver, Colombie Britannique, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2008
Divers
Thread ID:
01426219
Message ID:
01426240
Vues:
49
Actually it does work. After I restarted computers.
Now, while this
!NET USE LPT1: \\192.168.1.10\LawLabels
work on a remote computer in the Command window, but refuses to execute when I run it an EXE called from ASP page (Web).
Any idea?

>>I am trying to print a text file to a printer that is shared and connected to another computer.
>>
>>>>Is that possible? I need it for Windows 2003. The printer is a network printer.
>>>
>>>Can you elaborate on why you're trying to do this?
>>>
>>>If the printer is a GDI printer then no, you can't send "raw data". If it has its own print engine you should be able to.
>>>
>>>There are several possible configurations for "network printers" - which is your case?
>>>
>>>1. Printer has a network card. Print jobs travel directly from workstations to the printer
>>>2. Printer has a network card. Print jobs travel from workstations to a print queue on a server computer, which then sends them to the printer
>>>3. Printer is directly attached to a server computer via USB, parallel cable etc. Print jobs travel from workstations to a print queue on this server, which sends them to the printer
>
>
>REM On your workstation, in a CMD window:
>REM Redirect your local LPT1: printer port to the shared printer's queue:
>NET USE LPT1 \\ServerComputerName\SharedPrinterName (optional: add /persistent:y flag to end of this command)
>
>REM Print your text file by COPYing it to the LPT1: port with the binary switch:
>COPY MyTextFile.txt LPT1 /B
>
>REM Disconnect your LPT1 printer port from the remote queue:
>NET USE LPT1: /DEL
>
>The above will work only if the printer is NOT a GDI printer i.e. it supports printing from DOS applications.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform