Promotic
WikipediaLinkedInYoutubeTwitterFacebook

TestInGroup - method of object User

Description:
Test if the user is or isn't a member of the user group.
Syntax:
TestInGroup(sGroups As String) As Boolean
Calling:
b = User.TestInGroup(sGroup)
Parameters:
sGroups(String) The list of identifiers of the user groups (separated with comma ',') where the user is searched.
Return Values:
true - the user is a member of any listed group
false - the user isn't a member of any listed group
Note:
If the designer creates a permissions system in the application based on logical user groups, then the method enables to test from a script if the logged-on (or else) user is a member of the group.
Example:
Test if the local logged-on user is a member of the $OPER or $ADMIN group
If User.TestInGroup("$OPER,$ADMIN") Then
' ...
End If
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice