IMetabaseSecurity.ExportUsersList

Syntax

ExportUsersList(FileName: String);

ExportUsersList(System.String);

Parameters

FileName. Name and location of the file to which the object is exported.

NOTE. To export file as a table, specify file in CSV-format (*.csv).

Description

The ExportUsersList method exports user list to the file.

Comments

The files saves only information displayed in list of security manager that is why configured column display and filtering in used must be taken into account.

Example

To execute the example, add links to the Metabase, ForeSystem (for the Fore.NET example) system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Lic: Object;
Begin
    MB := MetabaseClass.Active;
    
// Check out license to work with security manager
    Lic := MB.RequestLicense(UiLicenseFeatureType.Adm);
    
// Export list of users to the file   
    MB.Security.ExportUsersList("C:\UsersList.csv");
    
// Check in license
    Lic := Null;
End Sub UserProc;

Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.ForeSystem;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Lic: Object;
Begin
    MB := Params.Metabase;
    
// Check out license to work with security manager
    Lic := MB.RequestLicense(UiLicenseFeatureType.lftAdm);
    
// Export list of users to the file   
    MB.Security.ExportUsersList("C:\_UsersList.csv");
    
// Check in license
    Lic := Null;
End Sub;

After executing the example the list of users will be exported as a table to the specified file.

See also:

IMetabaseSecurity