IWxMetabaseObject.MetabaseObject

Syntax

MetabaseObject: IMetabaseObjectDescriptor;

Description

The MetabaseObject property determines the repository object that is displayed on the workspace.

Example

Executing the example requires a form with the Button1 button, the WorkspaceBox component named WorkspaceBox1 and the UiWorkspaceObject component or the UiWorkspace component that is used as data source for WorkspaceBox1.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);

Var

MB: IMetabase;

Shape: IWxRectangle;

WxObj: IWxMetabaseObject;

Begin

MB := MetabaseClass.Active;

WorkspaceBox1.View.BeginUpdate;

Shape := WorkspaceBox1.View.Workspace.CreateRectangle;

Shape.Style.TextPosition := WxTextPosition.Bottom;

Shape.CreateExtension("KeWsp.WxMetabaseObject");

Shape.Id := "New_Shape";

WxObj := Shape.Extension As IWxMetaBaseObject;

WxObj.MetabaseObject := MB.ItemById("Etl");

WorkspaceBox1.View.EndUpdate;

End Sub Button1OnClick;

After executing the example, on clicking the button the object of repository with the Etl identifier is added to the workspace.

See also:

IWxMetabaseObject