almmatt
9 years agoContributor
Get current Windows user SID
Hello everyone, I am looking for a way to get the current Windows user SID during script execution. Part of our regression testing requires that we verify deleting an item within our application ...
- 9 years ago
Hi almmatt,
Try this:
function getSID() { var oWMI = GetObject("winmgmts:"); var oAccount = oWMI.Get("Win32_UserAccount.Name='" + Sys.UserName + "',Domain='" + Sys.DomainName + "'"); return oAccount.SID; }