Why not stop and return when validForm just turns false, like this:
On Mon, May 18, 2009 at 5:54 PM, Tim Hoff <[email protected]> wrote:
>
>
> *
>
> import
> * mx.core.UIComponent;
>
> *private* *function* formIsValid():Boolean
> {
>
> * for* (*var* i:int = 0; i < *this*.numChildren; i++)
> {
> * if* ( UIComponent(*this*.getChildAt(i)).errorString != *""* )
> {
> *return* *false*;
> }
> }
>
> * **return* *true*;
> }
>
> -TH
>
>
> --- In [email protected], "sminrana" <sminr...@...> wrote:
> >
> > first you trying to use numChildren as a method but it is not it is a
> > property which return int value and it is read-only so remove the () in
> the loop
> >
> > second what is errorString ???
> >
>
>
--
Ivan Perez - Desenvolvimento Tecnológico
TecSinapse - www.tecsinapse.com.br
11 9324-0097 / 19 8812-0809