>CtlSetEnabled( ...., false);

after this line call CtlEnabled(...) to check if it is returning true
or false.
Otherwise, check if yourCtl->attr->enabled = 0 or not.

Also, make a similar check in MyFunction() to check the enabled state
of the control.

>but when I press the button during the execution of Myfunction(), the
>system
>still respond to the button I pressed during that time after Myfunction()
>has finished.

may be CtlSetEnabled( ....., true); is already executed even before u
pressed on the button.


Anuradha



__________________________________________________
FREE voicemail, email, and fax...all in one place.
Sign Up Now! http://www.onebox.com


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to