UsrMgr_GetLocalGroupNameBySid
Description
Section titled “Description”Gets the name of the local group with the specified SID. This is useful for built-in groups, whose names differ between Windows languages.
If no local group has the SID, the function returns True, gbValue is False and gsValue is empty.
Syntax
Section titled “Syntax”UsrMgr_GetLocalGroupNameBySid(sSid) As Boolean
Parameters
Section titled “Parameters”sSid (String)
Section titled “sSid (String)”SID of the local group, for example S-1-5-32-544 for the Administrators group
Return value
Section titled “Return value”Result will be stored in gsValue.
Example
Section titled “Example”If bStatus Then bStatus = UsrMgr_GetLocalGroupNameBySid("S-1-5-32-544")If bStatus Then bStatus = Job_WriteLog("Custom", "gsValue: " & gsValue, bStatus, True)Related functions
Section titled “Related functions”UsrMgr_CreateLocalUser UsrMgr_CreateLocalGroup UsrMgr_GetSIDForLocalGroup Well-known SIDs Constants Package Property Variables