regRef Method


Registers a Composite Controls object with the cCompositeControls class instance's global object references collection.

Syntax

expression.regRef(obj)

expression A variable that represents a class object.

Parameters

Name Required / Optional Data Type Description
obj Required Object Object to be registered in the global object references collection.

Remarks

When the object is passed up the line to the cCompositeControls instance, the effort is made to register the object according to it's Tag property. Failing that, the memory address of the object is obtained using ObjPtr() and that address is used as a key. It is preferrable to ensure the Tag property has a proper and unique value.

Example

This example shows a cControl object registering it's cControlChild objects:

Dim child as cControlChild_MyControl

For Each child In colChildren

   regRef Child

Next child

Last edited Dec 23, 2010 at 11:33 AM by vba_junkie, version 2

Comments

No comments yet.