AllUsers: ISecuritySubjects;
The AllUsers property returns collection of all users, available in the current repository.
This collection includes all users which can be used on working in the repository:
Users created in the security manager of the repository.
Users having the attribute of the deferred loading of the description.
Domain users.
NOTE. For the users with the attribute if the deferred loading only the basic description will be available (Name, security subject type and security descriptor). To obtain all custom parameters use IMetabaseSecurity.ResolveName, IMetabaseSecurity.ResolveSid methods or search via IMetabaseSecurity.NewSubjectsSearch.
Sub Main;
Var
MB: IMetabase;
MS: IMetabaseSecurity;
Users: ISecuritySubjects;
User: ISecuritySubject;
Begin
MB := MetabaseClass.Active;
MS := MB.Security;
Users := MS.AllUsers;
For Each User In Users Do
Debug.WriteLine(User.Name);
End For;
End Sub Main;
After executing the example names of all users groups that are available in the current repository are displayed in the development environment console.
See also: