I did this (ironic I had the same problem at the same time), but now I have the undesired effect of the tab switching, then immediately switching back. Suggestions? Shan
_____ From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Tracy Spratt Sent: Tuesday, December 05, 2006 11:39 AM To: flexcoders@yahoogroups.com Subject: [Junk E-Mail - LOW] RE: [flexcoders] how to stop tab from changing Hmm, that looks ok. Maybe a timing issue with the rendering? Try setting the selectedIndex using callLater. Tracy _____ From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Yiðit Boyar Sent: Tuesday, December 05, 2006 7:58 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] how to stop tab from changing i have an accordion, in which when the user clicks sth inside the first tab; the second tab is loaded. the problem is that; i have to prevent user from opening the second tab. i need to show an error and reselect the 1st tab. to make this; i have added an event listener for the change event of the accordion but; i can give the error, but can not reselect tab 0. my code is below, can anyone help me please? thanks.. --- private function tabChangeControl(e:Event):void{ if(accordi.selectedIndex == 1 && bilgiler.enabled==false){ e.preventDefault(); Alert.show('Önce görev seçmelisiniz','Hata'); //error message accordi.selectedIndex=0; //THIS DOES NOT WORK!!! } } _____ Need a quick answer? Get one in minutes from people who know. Ask your question on Yahoo! <http://answers.yahoo.com/;_ylc=X3oDMTFvbGNhMGE3BF9TAzM5NjU0NTEwOARfcwMzOTY1 NDUxMDMEc2VjA21haWxfdGFnbGluZQRzbGsDbWFpbF90YWcx> Answers.