myComponent.mxml
------------------------------------------------
private var _myVar:ValueType;
public function set myVar(value:ValueType):void
{
if(value != null)
{
_myVar = value;
callSomeFunction(); //because this setter gets called whenever myVar is updated on myComponent, this function will get called
}
}
For more info, do a search on implicit getters and setters.
HTH,
Brendan
On 8/16/06, arnold_charming <[EMAIL PROTECTED]> wrote:
Hi!
I'm passing a string to my component with
<view:myComponent myVar="some string"/>
What I would like to do now is the following. When the value of myVar
changes I would like to dispatch an event, which would tell me the
current value of myVar. But now I don't know how to register this type
on an event in myComponent so it will be fired every time the myVar
changes. Can someone help me out? I'm really lost with these events
and I looked thru Adobe Developmnent Guide but nothing usefull.
__._,_.___
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
![]()
SPONSORED LINKS
Software development tool Software development Software development services Home design software Software development company
YAHOO! GROUPS LINKS
- Visit your group "flexcoders" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
__,_._,___
- [flexcoders] dispatching events on a change of a variable arnold_charming
- Re: [flexcoders] dispatching events on a change of a... Brendan Meutzner
- Re: [flexcoders] dispatching events on a change of a... Douglas Knudsen
Reply via email to

