One more question, how would I delete the old printer that has a different name than the share name, I tried putting the printer name on the remove line but it doesnt work either.

 Code:
if primapstate("\\server\HP LaserJet P4014 PCL6")
	$RC=delprinterconnection("HP LaserJet P4014/P4015 PCL6")
Endif


The share name is: "\\server\HP LaserJet P4014 PCL6"
and the printer name is: "HP LaserJet P4014/P4015 PCL6"