Item Property (TimeIntervals Collection)


See Also     Example     Applies To    

 

Item is a Read-Only property that returns a member from a TimeIntervals collection, by name or by position.  The return type is that of the object that the collection holds.

Syntax

object[.Item](Index[, LocaleIndependent])

The Item property syntax has these parts:

Part Description
object An object expression that evaluates to a TimeIntervals collection.
Index An expression that specifies a member of the collection, as described in Settings.
LocaleIndependent A boolean that indicates whether the passed index is in the current locale or not.

Settings

The settings for Index are:

Part Description
number Specifies the position number of a member of the collection. Must range from 1 to the value of the collection's Count property. (See Remarks for specifics.).
String Specifies a collection member by name, usually the Name property of a member of the collection. (See Remarks for specifics.).

Remarks

The Item property is the default property of the collection, so these expressions have the same meaning:

MyColl.Item(3)

MyColl(3)

In some collections, the position number of a collection member may change as new members are added.

Trappable Errors

In addition to generic errors (such as Out of Memory), the following errors may occur:

Error Description
tseNAMENOTFOUND The specified interval name was not found.
tseOUTOFRANGE The specified interval index was outside the number of items in the collection.

Enabling Operational Intelligence