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; } } 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.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; On May 26, 2011, at 3:41 PM, Karl DeSaulniers wrote: > .selectedIndex ?? > > > On May 26, 2011, at 2:36 PM, DONALD TALCOTT wrote: > >> .selectedIndices > > Karl DeSaulniers > Design Drumm > http://designdrumm.com > > _______________________________________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders DON TALCOTT 316 Greenwood Avenue Decatur, Georgia 30030 404.538.1642 dtalc...@mindspring.com _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders