Description

A read/write property reflecting object's Tag Number.

Property type

A Long value.  

Syntax

object.TagNumber [= value]

The TagNumber Property syntax has these parts:

PartDescription
objectAn expression evaluating to an object of type McObject.
valueA Long value.

Remarks

On assignment, a value of zero clears any existing TagNumber to zero (none). TagNumbers greater than zero must be unique for all objects sharing the same ParentMcObject. All positive TagNumbers are indexed for fast lookup by TagNumber and ParentMcObject with the McObjects.LookupByTagNumber function. Any number of objects may share a negative tag value. Tag numbers from -1 through -0xffff (-65535) are reserved for internal objects (any attempt to set one of these values results in an error), so assign numbers smaller than mcobjNegativeTagNumberBase (-0x10000) for your negative tag numbers.

You may also set the TagNumber during object creation by passing an argument to the McObjects.Add method or by supplying a TagNumber for the McObjects.AttachAutoAddToCategory method.

You cannot assign to the TagNumber property if the mcobjUserFlagSystemObject bit in the UserFlag property is set.