IMetabaseObjectDescriptor.SetIdNoCheck

Syntax

SetIdNoCheck(Id: String);

Parameters

Id - an identifier that should be set for the object.

Description

The SetIdNoCheck method changes an identifier of the object without checking it against the specified format of identifiers.

Comments

It is relevant to use this method if any format of identifiers was set for the repository. If the format of identifiers was not set, the Id property should be changed to changed the identifier of the object.

Example

Executing the example requires that the repository contains an object with the Obj_1 identifier.

Sub Main;

Var

MB: IMetabase;

MDesc: IMetabaseObjectDescriptor;

Begin

MB := MetabaseClass.Active;

MDesc := MB.ItemById("Obj_1");

MDesc := MDesc.EditDescriptor;

MDesc.SetIdNoCheck(MDesc.Id + "_Old");

MDesc.SaveDescriptor;

End Sub Main;

 

The identifier is added to the object after executing this example. The check of correspondence of the set format of identifiers is not performed.

See also:

IMetabaseObjectDescriptor