User Roles

Jul 15, 2009 at 8:45 AM

I need to get the Roles the specific user participate ?

 

eg.  John  in Admin, Members  roles

Coordinator
Jul 15, 2009 at 9:52 AM

Hi,

you can check access over all Items (Role types only) using direct CheckAccess or using (better) the StorageCache Objects.

See other post to get source code examples.

Regards,

Andrea.

__________________________________
Andrea Ferendeles
NetSqlAzMan - Project Coordinator

http://netsqlazman.codeplex.com

Jul 19, 2009 at 10:06 AM

I use this code :

ReDim Preserve roles(AzmanRoles.Length - 1)
            Dim index As Integer = 0
            For Each item As IAzManItem In AzmanRoles
                For i As Integer = 0 To item.Authorizations.Count - 1
                    If item.Authorizations(i).SID.StringValue = application.GetDBUser(userName).CustomSid.StringValue Then
                        roles(index) = item.Name
                        index += 1
                    End If
                Next
            Next