IDomain.Name

Syntax

Name: String;

Description

The Name property returns a name of the domain.

Comments

The property is read-only.

Example

To execute the example make sure that the security manager contains the DOMAIN_USER domain user with the access to workstations.

Add a link to the Metabase system assembly.

Sub UserProc;
Var
    MB: IMetabase;
    MS: IMetabaseSecurity;
    User: IMetabaseUser;
    St: IStations;
    Dm: IDomains;
    Domain: IDomain;
    i: Integer;
Begin
    MB := MetabaseClass.Active;
    MS := MB.Security;
    
// Get domain user parameters
    User := MS.ResolveName("DOMAIN_USER"As IMetabaseUser;
    St := User.Stations;
    Dm := St.Domains;
    
// Display domain user parameters to console
    Domain := Dm.Item(0);
    Debug.WriteLine(
"Domain: " + Domain.Name);
    Debug.WriteLine(
"Description: " + Domain.Comment);
    Debug.WriteLine(
"Access to workstations: ");
    
For i := 0 To Domain.Stations.Count - 1 Do
        Debug.WriteLine(Domain.Stations.Item(i).Name);
    
End For;
End Sub UserProc;

After executing the example the console displays the user domain, description, and list of allowed workstations.

See also:

IDomain