Did you change groupnames when you were at it? Although enumgroup will always return something for every domain user, still had to ask...

Setdefaultprinter needs \\server\printername

If your printer name is not exactly the same as your sharename, your script would indeed fail on that part


Edited by Lonkero (2016-08-11 02:40 PM)
Edit Reason: spell check
_________________________
!

download KiXnet