Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
Keywords: default printer
Also, the printer name and printer port turn out to be the same, at least in my local network situation. Here is the code that connects the printer AND sets the printer as the default printer. Thanks for the help....
AddExtender("WWPRT34I.DLL") result=pAddPrtConn("\\fohsfile01", "fohplp170102") if result==1 printername=pGetPrtList(0) If ItemCount(printername,@TAB)>1 myprn=AskItemList("Select Default Printer", printername, @tab, @sorted, @single) else myprn=ItemExtract(1,printername,@TAB) endif ret=pSetDefPrtEx(myprn,"",myprn) if ret==1 display(2,"Printer Connection","Connection to %myprn% successful") else Message("Printer Connection","Setting %myprn% as default - failed") endif else Message("Printer Connection","Connection to %myprn% failed") endif exit
Article ID: W14191
Filename: Connect Printer and Set the Default Printer Example.txt
File Created: 2017:07:28:12:58:37
Last Updated: 2001:03:01:14:38:20