The Surly Admin

Father, husband, IT Pro, cancer survivor

Disabling Users by CSV

Really interesting script came by recently on Spiceworks, written in vbScript.  As you know I like to take these scripts and see what I can do with them in Powershell with a special eye towards shortening it!  This script, Disable User Account from Text file, was written by stubar and is a really well done script.  I don’t want to take anything away from that.  But with Powershell we can do the same thing, and often do more with less code.  Here’s what I came up with.

Continue reading

October 1, 2012 Posted by | PowerShell | , , | 20 Comments