all groups > flash actionscript > june 2004 >
You're in the

flash actionscript

group:

Dynamic text box with multiple variables



Dynamic text box with multiple variables JFalk1
6/5/2004 9:46:13 PM
flash actionscript: I want to use several buttons to load different text into a single textbox. I
created an .html document with several variables separated by an "&". How can I
assign a different variable to the text box depending on which button is
pressed?
Re: Dynamic text box with multiple variables JFalk1
6/5/2004 11:16:02 PM
Re: Dynamic text box with multiple variables Laiverd.COM
6/6/2004 12:11:49 AM
myBtn1.onRelease = function(){
mytextfield.text = variable1;
}

myBtn2.onRelease = function(){
mytextfield.text = variable2;
}


John
--
----------------------------------------------------------------------------
-----------
RESOURCES
http://groups.google.com/advanced_group_search?hl=en&as_ugroup=*flash
----------------------------------------------------------------------------
-----------
TUTORIALS at
www.laiverd.com
Flash & PHP Emailform
Using textfiles in Flash
----------------------------------------------------------------------------
-----------

Re: Dynamic text box with multiple variables Laiverd.COM
6/6/2004 1:30:06 PM
To set text dynamically into textfields, you only need the instancename of
the field and its .text or .htmlText property. So indeed no need for a
variablenam in the properties panel. In the code provided, we're talking
instancename.

John

--
----------------------------------------------------------------------------
-----------
RESOURCES
http://groups.google.com/advanced_group_search?hl=en&as_ugroup=*flash
----------------------------------------------------------------------------
-----------
TUTORIALS at
www.laiverd.com
Flash & PHP Emailform
Using textfiles in Flash
----------------------------------------------------------------------------
-----------

Re: Dynamic text box with multiple variables JFalk1
6/6/2004 3:14:47 PM
Sorry, I edited my last question, but apparently not before you had replied. Now what I'm wondering is if I can use this method to load text with html formatting.

Re: Dynamic text box with multiple variables Laiverd.COM
6/6/2004 6:01:37 PM
Text is text to flash whether it contains HTML-tags or not. The only thing
you change is that u use the .htmlText property instead of the .text
property to get HTML-rendered text in the textfield.

John

--
----------------------------------------------------------------------------
-----------
RESOURCES
http://groups.google.com/advanced_group_search?hl=en&as_ugroup=*flash
----------------------------------------------------------------------------
-----------
TUTORIALS at
www.laiverd.com
Flash & PHP Emailform
Using textfiles in Flash
----------------------------------------------------------------------------
-----------

AddThis Social Bookmark Button