lets go back up please.
did you test at all why some of the scripts didn't work?
you must try to understand what is going on.
I mean, the script commands are clear english words so it won't be that hard.

you say your edited code worked but it looks to me just the same as my code.
tell me what this throws on your window:
Code:

break on

if substr(@wksta,1,3) = "PTE"
"part of PTE" ?
$Room = substr(@wksta,4,4)
"Room = " $Room ?
if substr($Room,1,1) = "0"
"Room started with zero, removing it." ?
$Room = substr($Room,2)
"Room is now " $Room ?
endif
"Connecting to Printer '\\PTE0705A06\HP"+$Room+"' "
$retval = AddPrinterConnection("\\PTE0705A06\HP"+$Room)
@error ?
$retval = SetDefaultPrinter("\\PTP0705A06\HP"+$Room)
endif



the default printer...
well, you need to know the printers name and use it instead of the share name if they are different.
_________________________
!

download KiXnet