IWxShapes.Count

Syntax

Count: Integer;

Description

The Count property returns the number of workspace objects.

Example

Executing the example requires that repository contains a workspace with the WSP identifier containing several shapes.

Add links to the Andy, Metabase system assemblies.

Sub UserProc;
Var
    mb: IMetabase;
    wsp: IWxWorkspace;
    view: IWxView;
    Shape: IWxShapes;
    i: Integer;
Begin
    // Get workspace for editing
    mb := MetabaseClass.Active;
    wsp := mb.ItemById("WSP").Edit As IWxWorkspace;
    view := wsp.CreateView;
    Shape := wsp.Shapes;
    For i := 0 To Shape.Count - 1 Do
    view.SelectedShapes.Add(wsp.Shapes.Item(i));
    End For;
    view.GroupSelectedShapes;
    (wsp As IMetabaseObject).Save;
End Sub UserProc;

After executing the example all objects located in the workspace are merged into a group.

See also:

IWxShapes