ISecurityPackage.CopyCredentials

Syntax

CopyCredentials(Value: ICredentials): ICredentials;

Parameters

Value. Credentials data source.

Description

The CopyCredentials method copies account from the object that is represented as an input parameter.

Example

Sub UserProc;
Var
    MB: IMetabase;
    Session: ILogonSession;
    Package: ISecurityPackage;
    Creds, CredsNew: ICredentials;
Begin
    MB := MetabaseClass.Active;
    Session := MB.LogonSession;
    Package := New StandardSecurityPackage.Create;
    Creds := Session.Credentials("DB");
    CredsNew := Package.CreateCredentials(AuthenticationMode.Password);
    CredsNew := Package.CopyCredentials(Creds);
End Sub UserProc;

After executing the example the CredsNew variable contains the credentials copied from credentials of an active repository.

See also:

ISecurityPackage