Item [ScaleBars]
Item returns an individual scale bar. Returns a ScaleBar object. This is the default method for the ScaleBars object.
Syntax
object.Item( Index )
Parameter |
Type |
Required/ Optional |
Default |
Description |
Index |
Variant |
Required |
This provides the index value. |
Example 1
This example demonstrates how to return a reference to the scale bar object then renames the scale bar. (You have to add the scale bar first.)
'returns a reference to the scale bar object
Set sbar = ScaleBars.Item(1)
'change the name of the referenced scale bar
sbar.Name = "Scale Bar in Miles"
Example 2
This example demonstrates how to return the name of the scale bar.
Debug.Print ScaleBars.Item(1).Name
Used by: ScaleBars collection