Use On Error Resume Next. Then try to access one of the control's properties
and check Err.Number to see if an error occurred.
Note that you can use UBound to find the upper bound of a control array.
For example, if lblName is a control array, then lblName.LBound and
lblName.UBound give the array's lower and upper bounds.
However, this does not mean every index is defined in between. Controls with
indexes 0 and 5 may be loaded while no other controls are loaded.
|