Workspace: IWorkspace;
The Workspace property determines the repository workspace, which data is further displayed in the WorkspaceBox component.
Executing the example requires a form with the Button1 button, the WorkspaceBox component named WorkspaceBox1, and the UiWorkspaceObject component that is used as the data source for WorkspaceBox1.
Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
MB: IMetabase;
Wsp: IWorkspace;
Begin
MB := MetabaseClass.Active;
Wsp := MB.ItemById("Wsp_1").Bind As IWorkspace;
UiWorkspaceObject1.Workspace := Wsp;
UiWorkspaceObject1.Active := True;
WorkspaceBox1.Source := UiWorkspaceObject1 As IWorkspaceSource;
End Sub Button1OnClick;
After executing the example, on clicking the button the UiWorkspaceObject1 component is connected with the workspace and the Wsp_1 identifier. Data is displayed in the WorkspaceBox1 component.
See also: