Question: Is the share name of the printer "SALES_R1045" identical to the printer name SALES_R1045". This is an important distinction. Additionally, when you look at your printer list, did you refresh the list after running the script?

I do have to agree with Jooel, that the error codes in Kixtrat are very reliable as they are received directly from the Windows API. Aslo, you are the only oen reporting this particular problem, which would indicate that it might rather be a problem with the computer you are testing it on. there at a lot of settings in windows XP, especially security settings wich can influence somethings seemingly as simple as adding printers or setting default printers.

You can always install Windows XP in an out-of-the-box configuration and retest your script. This woudl actually be a necessary step to show whether it's a script, Windows, or configuration problem.
_________________________
There are two types of vessels, submarines and targets.