IMetabase.DeleteObjectO

Fore Syntax

DeleteObjectO(Options: Integer; Key: Integer);

Fore.NET Syntax

DeleteObjectO(Options: integer; Key: uinteger);

Parameters

Options. Method of deleting links to repository objects.

Key. Repository object key, links to which must be deleted.

Description

The DeleteObject method deletes links to repository objects.

Comments

Value of the DeleteObjectOptions enumeration is used as the Options parameter.

Fore Example

Executing the example requires MDM dictionaries with the NSI_1 identifier.

Add links to the Metabase, Rds system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Obj: IMetabaseObjectDescriptor;
Begin
    MB := MetabaseClass.Active;
    Obj := MB.ItemById("DICT");
    MB.DeleteObjectO(0, Obj.Key);
End Sub UserProc;

After executing the example links to other repository objects are checked for the specified object. Links to repository objects are not deleted.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.Rds;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Obj: IMetabaseObjectDescriptor;
Begin
    MB := Params.Metabase;
    Obj := MB.ItemById["DICT"];
    MB.DeleteObjectO(1, Obj.Key);
End Sub;

See also:

IMetabase