Try this...
On May 26, 2011, at 3:27 PM, DONALD TALCOTT wrote:
function submitHandler(e:MouseEvent) {
var myArr:Array = topskillsfield.selectedIndices;
var selectedTopSkills:String = "";
for(var i:int = 0; i < myArr.length; i++) {
var j:int = myArr[i];
if(selectedTopSkills == "") {
selectedTopSkills = topskillsfield.getItemAt(j).data;
} else {
selectedTopSkills += ", " + topskillsfield.getItemAt
(j).data;
}
}
return selectedTopSkills;
//trace("selectedTopSkills: " + selectedTopSkills);
}
my trace ouputs the following: selectedTopSkills: Written
Communication, Networking, Public Speaking, Negotiation, Strategic
Planning
When I use the following in my variables, the number of selections
(5) is posted to db.
I need to post "Written Communication, Networking, Public Speaking,
Negotiation, Strategic Planning" to the db.
var variables:URLVariables = new URLVariables();
variables.firstname = fnamefield.text;
variables.lastname = lnamefield.text;
variables.title = titlefield.text;
variables.dept = deptfield.value;
variables.email = emailfield.text;
variables.nickname = mc_one.nicknamefield.text;
variables.birthday = mc_one.birthdayfield.text;
variables.anniversary = mc_one.anniversaryfield.text;
//variables.topskills = mc_two.topskillsfield.selectedIndices;
variables.topskills = selectedTopSkills; // Must be set after above
function is called.
variables.rightlefthanded = mc_three.radioGroup1.selection.value;
variables.hometown = mc_four.hometownfield.text;
variables.college = mc_four.collegefield.text;
variables.achievement1 = mc_five.achievement1field.text;
variables.achievement2 = mc_five.achievement2field.text;
variables.photo = mc_six.photo.fileDisplay_txt.text;
HTH,
Best,
Karl DeSaulniers
Design Drumm
http://designdrumm.com
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders