I want to loop through all of the children of a flex object and find 
all children of a specific type.

I have code that works, but it looks really kludgy;

for each (var field:Object in object.getChildren())
{
  if (field.constructor.toString() == "[class ValidatedTextInput]")
  {
    field.validateData();
    if (bolAllValid ) bolAllValid = field.isValid;
  }
}

Like I said it works, but there has got to be something better than;

if (field.constructor.toString() == "[class ValidatedTextInput]")

All help is rewarded with an attaboy!

Actually it is greatly appreciated, but it is getting late.

Paul


Reply via email to