|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
connect to the shared printer when start-upI want to connect to the share printer when I start up.
I put a batch file into the start up folder so it runs every time the system boots. For example, the server IP is 10.10.10.10 and the name of shared printer is "shared_printer", then how can make the batch file? Thanks. Kang-
Open up notepad and type this in: start wscript.exe c:\prinstall.vbs exit Save the file as "C:\prinstall.bat" (use the quotes) Open a new notepad and type this in: Set WshNetwork = CreateObject("WScript.Network") WshNetwork.AddWindowsPrinterConnection "\\10.10.10.10 \shared_printer" WshNetwork.SetDefaultPrinter "\\10.10.10.10 \shared_printer" wscript.quit Save the file as "c:\prinstall.vbs" (with the quotes) Create a shortcut to C:\prinstall.bat and put it in your startup folder If you have any problems please let me know, otherwise enjoy! Nick Show quoteHide quote "Kang" wrote: > I want to connect to the share printer when I start up. > I put a batch file into the start up folder so it runs every time the system > boots. > For example, the server IP is 10.10.10.10 and the name of shared printer is > "shared_printer", then how can make the batch file? > > Thanks. > > > Please note that the script should contain 4 lines (due to formatting it may
have posted otherwise). The lines should begin: Set WshNetwork WshNetwork WshNetwork wscript.quit thanks Show quoteHide quote "Nick Staff" wrote: > Kang- > > Open up notepad and type this in: > > start wscript.exe c:\prinstall.vbs > exit > > Save the file as "C:\prinstall.bat" (use the quotes) > > Open a new notepad and type this in: > > Set WshNetwork = CreateObject("WScript.Network") > > WshNetwork.AddWindowsPrinterConnection "\\10.10.10.10 \shared_printer" > WshNetwork.SetDefaultPrinter "\\10.10.10.10 \shared_printer" > > wscript.quit > > Save the file as "c:\prinstall.vbs" (with the quotes) > > Create a shortcut to C:\prinstall.bat and put it in your startup folder > > If you have any problems please let me know, otherwise enjoy! > > Nick > > "Kang" wrote: > > > I want to connect to the share printer when I start up. > > I put a batch file into the start up folder so it runs every time the system > > boots. > > For example, the server IP is 10.10.10.10 and the name of shared printer is > > "shared_printer", then how can make the batch file? > > > > Thanks. > > > > > >
Domain Controller?
Urgent - NT Remote Authentication API Windows 2003 RIS ERROR HELP -Need instructions on running Service Pack from cmd prmpt Trouble with adding existing user to SBS 2003 network available disk space Using WMI to determine boot device priority schema master Where get Microsoft SPY++ utility? virtual memory |
|||||||||||||||||||||||