Just put an end function error statement after the remove printer connection and on to the add printer connection.


----Original Message Follows----
From: "Jason Tolentino" <[EMAIL PROTECTED]>
Reply-To: "NT 2000 Discussions" <[EMAIL PROTECTED]>
To: "NT 2000 Discussions" <[EMAIL PROTECTED]>
Subject: OT: VBScript help
Date: Mon, 11 Aug 2003 10:28:00 -0700

Hi--
I am attempting to write a login script that will check if a [network]
printer exists on local computer. if it does exist, proceed to remove
[the old path] and reinstall from a new print server. I'm no expert at
this and any help would be very much appreciated.

Kinda like this:

on error resume next
Set WshNetwork = CreateObject("WScript.Network")

>>>>>>> If "\\oldserver\oldprintername" exists then  <<<<<<having
trouble with this part.

WshNetWork.RemovePrinterConnection "\\oldserver\oldprintername"
WshNetwork.AddWindowsPrinterConnection "\\newserver\nerprintername"

thanks


------
You are subscribed as [EMAIL PROTECTED]
Web Interface: http://intm-dl.sparklist.com/cgi-bin/lyris.pl?enter=nt2000&text_mode=&lang=english
To unsubscribe send a blank email to %%email.unsub%%


_________________________________________________________________
Hotmail messages direct to your mobile phone http://www.msn.co.uk/msnmobile


------ You are subscribed as [EMAIL PROTECTED] Web Interface: http://intm-dl.sparklist.com/cgi-bin/lyris.pl?enter=nt2000&text_mode=&lang=english To unsubscribe send a blank email to [EMAIL PROTECTED]

Reply via email to