Title: Message
You never actually call your addnumbersup() function.  If you place it in your placenumberdown() function, it should start working.  For example:
 
public function placenumberdown(){
    addnumbersup();
    thenumberitself.text =String(addup);
}
 
 

Thank you,
Greg Andora

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Friday, April 01, 2005 10:59 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Making an array of buttons

I am trying to make an array of Objects that hold Number values and for some reason this code does not work can someone explain why it does not work? I am trying to get it to show the number ten in the TextInput box.
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.macromedia.com/2003/mxml">
<mx:Script>
<![CDATA[
public var addup:Number
public function addnumbersup(){
addup =numberstoaddup[0].Number+numberstoaddup[1].Number+numberstoaddup[2].Number+numberstoaddup[3].Number+numberstoaddup[4].Number
}
public function placenumberdown(){
thenumberitself.text =String(addup)
}
]]>
</mx:Script>
<mx:Array id="numberstoaddup">
 
<mx:Object Number ="0"/>
<mx:Object Number ="1" />
<mx:Object Number ="2" />
<mx:Object Number ="3" />
<mx:Object Number ="4" />
 

</mx:Array>
<mx:HBox><mx:Button  label="click" id="makenumber" click="placenumberdown()"/><mx:TextInput editable="false" id="thenumberitself" /></mx:HBox>
 
</mx:Application>


Yahoo! Groups Links

----
This email may contain confidential and privileged material for the sole use of the intended recipient(s). Any review, use, distribution or disclosure by others is strictly prohibited. If you are not the intended recipient (or authorized to receive for the recipient), please contact the sender by reply email and delete all copies of this message.

To reply to our email administrator directly, send an email to
[EMAIL PROTECTED]

Littler Mendelson, P.C.
http://www.littler.com


Reply via email to