cyle
asked on
Using lotus script for User Roles.
I need to validate if the user, based on user roles but I need to use lotus script. Thanks!
From the help:
Dim session As New NotesSession
Dim db As NotesDatabase
Dim acl As NotesACL
Dim entry As NotesACLEntry
Set db = session.CurrentDatabase
Set acl = db.ACL
Set entry = acl.GetEntry( "Bob Kidder" )
Forall r In entry.Roles
Messagebox( r )
End Forall
Dim session As New NotesSession
Dim db As NotesDatabase
Dim acl As NotesACL
Dim entry As NotesACLEntry
Set db = session.CurrentDatabase
Set acl = db.ACL
Set entry = acl.GetEntry( "Bob Kidder" )
Forall r In entry.Roles
Messagebox( r )
End Forall
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Evaluate("@UserRoles") actually works better, because the other two methods can be used against named ACL entries. If the user is in a role as part of a group, they will fail. @UserRoles never fails that way. Forewarned: Occasionaly, Evaluate of @UserRoles doesn't pick up changes correctly.
Perhaps not the fastest, but certainly the easiest way!