Shapes Property
Shapes returns the Shapes collection. Returns a Shapes collection. This is a read-only property.
Syntax
object.Shapes
Example 1
This example demonstrates how to return the number of objects in a plot document.
Debug.Print Plot.Shapes.Count
Example 2
This example demonstrates how to create a rectangle.
Dim Rectangle As Object
Set Rectangle = Plot.Shapes.AddRectangle(Left:=5, Top:=7, Right:=6, Bottom:=10)
Example 3
This example uses the Shapes property to change the text properties of an object within a composite object
Set Composite = Plot.Import2(FileName:=SurferApp.Path+"\Samples\DemoText.mif")
Composite.Shapes.Item(3).Text = "My New Text"
Composite.Shapes.Item(3).Font.ForeColorRGBA.Color = srfColorBlue
Example 4
This example changes a few object properties and breaks apart a composite object in a base map layer.
BaseLayer.Shapes.Item(1).Fill.Pattern = "Solid"
BaseLayer.Shapes.Item(2).Name = "Yolo County"
BaseLayer.Shapes.Item(2).SetZOrder(srfZOToFront)
Example 5
This script displays all the methods and properties in the PlotDocument object.
Used by: Composite Object, PlotDocument object, VectorBaseLayer Object