IMetabaseObjectDescriptor.Share

Syntax

Share;

Description

The Share method puts the object into the version control system.

Comments

If this method is activated, the window of the first publishing of the object in the version control system will be displayed on the screen.

If the following conditions are fulfilled, the window of publishing will be displayed:

If even one condition is not fulfilled, the activation of the method does not yield any result.

Example

The ShareObject function is described in the example.

Add a link to the Metabase system assembly.

Function ShareObject(Descriptor: IMetabaseObjectDescriptor): Boolean;
Begin
    If Descriptor.IsSharingSupported And (Not Descriptor.IsShared) Then
        Descriptor.Share;
        Return True;
    Else
        Return False;
    End If;
End Function ShareObject;

This function checks whether it is possible to add object to the version control system. If the necessary conditions are fulfilled, the object are placed in the version control system and function will returns the True value. The description of object is passed in the Descriptor parameter.

See also:

IMetabaseObjectDescriptor