Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
CopyFile
Message
 
À
17/01/2000 10:13:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Titre:
Divers
Thread ID:
00318954
Message ID:
00319118
Vues:
21
>>I was wondering if anyone has had any success using the CopyFile Win32Api call to print to a Novell network printer. It works for me to print to PRN (my default printer), and it works when I copy a file to the file server, but when I specify \\FileServerName\PrinterName, it does not work. Any ideas? An example:
>>
>>DECLARE INTEGER CopyFile IN KERNEL32.DLL ;
>> STRING @SourceFileName, ;
>> STRING @DestFileName, ;
>> INTEGER bFailIfExists
>>=CopyFile("c:\autoexec.bat","\\fs1\QMIS",0)
>
>You have to specify a queue name and it's the name of the print server, which may not be the same as the file server's name.
>
>If you can't get it to work this way, you may want to try mapping the printer to a local port (the WSH's Wscript.Network object has a method AddPrinterConnection that can do this if you don't want to use the Novell command line CAPTURE command ahead of time) and then copy to the port.

I can't seem to get CAPTURE to work correctly either. I capture the port, send the file, but it only sends the first 6K (out of 1.3M) and stops. Upon further research of the print server, when I do a Novell Capture of the printer in Windows Explorer, it wants to map it to \\SYS\.QMIS.058. I've tried using that, or \\SYS\058\QMIS, or .QMIS.058.SYS and every conceivable combination of that as queue name and nothing has worked. Is it possible to just send to a Windows defined printer?
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform