Quick Flash Que
- Started
- Last post
- 20 Responses
- rabattski&rabattski0
that should be possible. isn't there a standard listener for it?
- stewart0
now that is quick paul
sorry - don't know nothing about listeners yet...
- rabattski&rabattski0
well. i've never made something like that but it would really surprise if it can't be done. actually impossible. either an onevent / listener kind of thing. see what the rest comes up with. prolly more helpfull as well.
- stewart0
hope so.
because duplicate + scale MC 1 didn't work for some reason :)
- tomkat0
just give them the same variable name.
- stewart0
thats it, tomkat ?!
- tomkat0
i think so. put in variable f.e. _root.varname and they will show the same text..
- stewart0
okay, thanks tomkat.
it is working - half.now the variable name i gave them, appears in both text area's after publishing in IE...
- stewart0
got it now.
that was a real quicky.thanks tomkat.
- unfittoprint0
or
myListener = new Object();
myListener.onChanged = function(txt) {
MC.text2.text = text1.text;
trace(txt)
};
text1.addListener(myListener);
- stewart0
is that a better way unfit,
or just more complex ?
- unfittoprint0
If you want to have your code in just 1 place, yes... and you can add more code to the onChanged function (like making a typing sound, changing an MC's color, even tracing the number of characters you've written....)
- stewart0
ohkay.
but i can't get your script working...
whatever. thanks.
- unfittoprint0
remember:
text1 and text2 are the name of the texbox instances and NOT the name of variables [leave the variable field blank]
- stewart0
man, you are so paranormally gifted, unfit.
- stewart0
okay, it's working now.
but what exactly is the function of
trace(txt);
??it only generates an output of the name of the first textfield?
i deleted it.
- unfittoprint0
good.
was just for testing purposes.
- stewart0
now i know why you have so much time to hang around here in NT unfit.
you're so good in AS that you finished your projects before you even started them.
- tomkat0
true, stewart.
unfit's method is way more functional&professional, of course..
i just thought you were up for a quick shot..
- stewart0
haha!
i was up for a quiky, tomkat.but you're never too old to learn.
so, WTF are Listeners?