Declare Long NetApiBufferFree in NetAPI32 Long lpBuffer Declare Long NetUserGetGroups in NetAPI32 ; String wServerName, String wUserName, Long nLevel, ; Long @lpBuffer, Long @nMaxBufLen, Long @nEntriesRead, Long @nTotal Declare Long NetUserGetLocalGroups in NetAPI32 ; String wServerName, String wUserName, Long nLevel, Long nFlags, ; Long @lpBuffer, Long @nMaxBufLen, Long @nEntriesRead, Long @nTotal Declare Integer lstrlenW in Kernel32 as GetStrLenW Long lpString Declare Long RtlMoveMemory in Kernel32 as CopyMem2Num ; Long @nDest, Long lpSource, Long nLength Store 0 to pBuffer, nEntries, nTotal * wServerName = strconv(strconv( '\\TheServer'+chr(0), 1), 5) wServerName = Null && local computer wUserName = strconv(strconv( GetEnv( 'UserName' )+chr(0), 1), 5) *** Try this for Server * nStatus = NetUserGetGroups( wServerName, wUserName, 0, ; * @pBuffer, -1, @nEntries, @nTotal ) nStatus = NetUserGetLocalGroups( wServerName, wUserName, 0, 0, ; @pBuffer, -1, @nEntries, @nTotal ) If (nStatus == 0) and (nEntries > 0) pGroupName = 0 For nI = 0 to nEntries-1 CopyMem2Num( @pGroupName, pBuffer + (4*nI), 4 ) nLen = GetStrLenW( pGroupName ) * 2 ? 'GroupName: ' + strconv(strconv( sys( 2600, pGroupName, nLen ), 6), 2) Next endif If (pBuffer != 0) NetApiBufferFree( pBuffer ) endifHTH