Andy,
myComponent.setStyle("alpha", .5);
Whay do you use setStyle()? Since alpha is a property, this just seems to use more overhead by calling two methods instead of one. Since all UIComponent implement IUIComponent that extends IFlexDisplayObject that declares alpha, you even have a straight forward interface into the component. IUIComponent(myComponent).alpha = 0.5; Just curoius, Peace, Mike On 11/30/06, Sam Shrefler <[EMAIL PROTECTED]> wrote:
Andy: Thank you very much!!! Sam On 11/29/06, Andrew Trice <[EMAIL PROTECTED] > wrote: > > Sorry… let me elaborate more. The previous example would be used > inside of the component that is being enabled/disabled. To do this outside > of a component, you need to do it in actionscript: > > > > myComponent.enabled=fase; > > myComponent.setStyle("alpha", .5); > > > > > > _____________________________________ > > *Andrew Trice* > > Cynergy Systems, Inc. > > http://www.cynergysystems.com > > > > Blog: http://www.cynergysystems.com/blogs/page/andrewtrice > > Email: [EMAIL PROTECTED] > > Office: 866-CYNERGY > > > ------------------------------ > > *From:* [EMAIL PROTECTED] ups.com [mailto:[EMAIL PROTECTED] ups.com] > *On Behalf Of *Andrew Trice > *Sent:* Wednesday, November 29, 2006 4:19 PM > *To:* flexcoders@yahoogroups.com > *Subject:* RE: [flexcoders] Change alpha properties when setting enabled > property > > > > override public fuction set enabled(value:Boolean) : void > > { > > super.enabled = value; > > this.setStyle("alpha", ( value ? 1 : .5)); > > } > > > > Enjoy! > > > > -Andy > > _____________________________________ > > *Andrew Trice* > > Cynergy Systems, Inc. > > http://www.cynergysystems.com > > > > Blog: http://www.cynergysystems.com/blogs/page/andrewtrice > > Email: [EMAIL PROTECTED] > > Office: 866-CYNERGY > > > ------------------------------ > > *From:* [EMAIL PROTECTED] ups.com [mailto:[EMAIL PROTECTED] > *On Behalf Of *Sam Shrefler > *Sent:* Wednesday, November 29, 2006 3:52 PM > *To:* flexcoders@yahoogroups.com > *Subject:* [flexcoders] Change alpha properties when setting enabled > property > > > > Could someone tell me how to modify the alpha settings when setting a > component to enabled="false"? > > Thanks! > > Sam > >
-- Teoti Graphix http://www.teotigraphix.com Blog - Flex2Components http://www.flex2components.com You can find more by solving the problem then by 'asking the question'.