Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

automatically installing network computer

Status
Not open for further replies.

CorySnyder

Technical User
Jun 3, 2003
10
0
0
US
Is there a way to install a network printer on a local machine with VB.net? I found code that will set the default printer to a local printer, but I would like to automatically set up a network printer.

Thanks
 
I think a found a way to do it.

Dim net
net = CreateObject("WScript.Network")
net.AddWindowsPrinterConnection("printername")
net.SetDefaultPrinter("printername")

Let me know if there are problems with this.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top