how can i add a radiobutton value from the number at resultTxt.text... here is 
my code.. it wont do the math.. all it does is puts the value right beside the 
numbers at resultTxt.text.. help.. 

stop();

var gRB:RadioButtonGroup = RadioButtonGroup.getGroup("genderGroup");
gRB.addEventListener(MouseEvent.CLICK, genderHandler);

function genderHandler(event:MouseEvent):void {
    trace("event.target.selection.name", event.target.selection.name);
    trace("event.target.selection.value", event.target.selection.value);
    trace("resultTxt.text", resultTxt.text);
    
    switch(event.target.selection.name) {
        case "maleRB":
            maleRB.value = 1;
            break;
        case "femaleRB":
            femaleRB.value = 0;
            break;
    }
    resultTxt.text = parseInt(resultTxt.text) + 
(event.target.selection.value).toString();
}



      
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to