IMetabaseUser.MaxLogonSessions

Fore Syntax

MaxLogonSessions: Integer;

Fore.NET Syntax

MaxLogonSessions: System.Int32;

Description

The MaxLogonSessions property determines the maximum count of concurrent repository connect sessions for the user.

Comments

In case the maximum allowed connection sessions number is exceeded the user is shown the corresponding message and gets the new connection terminated.

The property default value is "0", which means the connection sessions number is unlimited.

Fore Example

Executing the example requires that the current repository security manager contains the User_1 user included to the user list.

Sub UserProc;
Var
    MB: IMetabase;
    Security: IMetabaseSecurity;
    User: IMetabaseUser;
Begin
    MB := MetabaseClass.Active;
    Security := MB.Security;
    User := Security.ResolveName("User_1"As IMetabaseUser;
    User.MaxLogonSessions := 5;
    Security.Apply;
End Sub UserProc;

The example execution results in setting the current repository connection sessions maximum number for the specified user.

Fore.NET Example

Executing the example requires that the current repository security manager contains the User_1 user included to the user list.

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Security: IMetabaseSecurity;
    User: IMetabaseUser;
Begin
    MB := Params.Metabase;
    Security := MB.Security;
    User := Security.ResolveName("User_1"As IMetabaseUser;
    User.MaxLogonSessions := 5;
    Security.Apply();
End Sub;

This procedure is an entry point for the .NET assembly. The example execution results in setting the current repository connection sessions maximum number for the specified user.

See also:

IMetabaseUser