>Hello Alonso,
>
>Is your login form modal? After this form is released, the main program (or the calling program is going to continue. Modal forms do not use a 'READ EVENTS' command.
>
>For example:
>
>
>* pretend main program
>do form loginForm
>read events
>
>
>
>It sounds like you want to go 2 possible directions based what the user does in this form. You might need something like this:
>
>
>* pretend main program
>do form loginForm to lSuccess
>if lSuccess
> do mainMenu
> read events
>else
> * end of main program...foxpro will quit here
>endif
>
>
>Use the unload method of loginForm to return a true or false value. I know I'm leaving out a lot of stuff that also goes in your main program.
>
>HTH,
Thanks, Steve.
I forgot to tell that my login form is a class not a form. But your idea worked, instead of
do form loginForm to lSuccess
I used a
PUBLIC variable. and everything worked fine.
Thanks to Alexandre and Tommy, too!
Alonso
Like Frank said: "I did it... MY WAY!"