On Wed, 25 Oct 2006 10:06:53 -0700
"Free, Bob" <[EMAIL PROTECTED]> wrote:
> whoami /groups
>
> C:\Admin\Util>where whoami
> C:\Program Files\Support Tools\whoami.exe
>
> Not exacty "stock" but then again I consider Support Tools as an
> essential part of an installation :-)
Well I can't ship that with my product.
I scraped up this VBS script that does the trick.
if WScript.Arguments.Count = 0 then
WScript.Echo "Usage: [cscript|wscript] ListGroups.vbs
<nETBIOSName>/<sAMAccountName>"
WScript.Quit 1
end if
Set UserObj = GetObject("WinNT://" & Replace(WScript.Arguments.Item(0), "\",
"/"))
For Each GroupObj In UserObj.Groups
List = List & GroupObj.Name & vbcrlf
Next
WScript.Echo List
Thanks,
Mike
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Michael B Allen
> Sent: Wednesday, October 25, 2006 9:47 AM
> To: [email protected]
> Subject: [ActiveDir] List Groups I'm In?
>
> Was is the easiest way for a user (say on a stock XP client) to list
> what groups they're in?
>
> Specifically I'd like the user to be able to just type a command like
> 'net user list groups' or some such and get a list of NT Account names
> for tokenGroups.
>
> Or if there is a dialog somewhere that's good too.
>
> Ideas?
>
> Mike
>
> --
> Michael B Allen
> PHP Active Directory SSO
> http://www.ioplex.com/
> List info : http://www.activedir.org/List.aspx
> List FAQ : http://www.activedir.org/ListFAQ.aspx
> List archive: http://www.mail-archive.com/[email protected]/
> List info : http://www.activedir.org/List.aspx
> List FAQ : http://www.activedir.org/ListFAQ.aspx
> List archive: http://www.mail-archive.com/[email protected]/
>
--
Michael B Allen
PHP Active Directory SSO
http://www.ioplex.com/
List info : http://www.activedir.org/List.aspx
List FAQ : http://www.activedir.org/ListFAQ.aspx
List archive: http://www.mail-archive.com/[email protected]/