Class SmartTags (Access VBA)
The class SmartTags represents the collection of smart tags for a control on a form, report, or data access page. To use a SmartTags class variable it first needs to be instantiated, for example
Add
Adds a smart tag to a form or control.
Add (Name)
Name: The name of the smart tag to add.
Dim strName As String: strName =
Dim stg As SmartTag
Set stg = CreateControl.SmartTags.Add(Name:=strName)
Count
You can use the Count property to determine the number of items in a specified collection.
CreateControl.SmartTags.Count
Item
The Item property returns a specific member of a collection either by position or by index.
If the value provided for the Index argument doesn't match any existing member of the collection, an error occurs. The Item property is the default member of a collection, so you don't have to specify it explicitly. For example, the following two lines of code are equivalent.
Item (Index)
Index: An expression that specifies the position of a member of the collection referred to by the expression argument. If a numeric expression, the Index argument must be a number from 0 to the value of the collection's Count property minus 1. If a string expression, the Index argument must be the name of a member of the collection.
Debug.Print Modules(0)