  | | | Changing text inside a button at runtime | Changing text inside a button at runtime 2004-03-19 - By Collin Peters
Back If I have a button instance that just has a piece of text on it, how can I change the value of that text at runtime?
i.e. If I take and drag 2 instances of the above button from the library to the stage. Name one instance1_btn and the other instance2_btn. How can I then change the instance1_btn's text to "One", and instance2_btn's text to "Two". For examples sake, the name of the dynamic text field in the button is 'label_txt'.
In a movieclip, I would normally accomplish this my saying instance_mc.label_txt.text = "Label", but when I print out the properties of a button with a for loop I do not see the text field.
Collin
=-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- Supported by Fig Leaf Software =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- Be sure to check the archives and the wiki: http://chattyfig.figleaf.com/ =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- http://chattyfig.figleaf.com/cgi-bin/ezmlm-cgi?1:mss:107505 =-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- -- To unsubscribe send a blank e-mail to: Normal Mode: flashcoders-unsubscribe@(protected) Digest Mode: flashcoders-digest-unsubscrive@(protected)
|
|
 |