I posted this as a reply in one of my other questions, so I apologize in
advance if I appear to be spamming things. I've modified the question,
anyway.
------
Hey all.. I just have a question about forms in FLEX 2:
I've got a repeater populated by a list of musicians taken from an XML
file. Each artist is represented by a checkbox and when a submit button
is clicked, I want that array to be sent over to a php script.
This is the vbox containing the artist info and checkbox:
<mx:VBox>
<mx:Text text="{artistRepeat.currentItem.name}" />
<mx:Image source =
"{artistRepeat.currentItem.image}" scaleContent="true" />
<mx:CheckBox data="{artistRepeat.currentItem.name}" id="cBox"
click="modifyArray(Object)" />
<mx:Text text="{cBox.data}" />
</mx:VBox>
And the function for handling this is:
public function modifyArray(item:Object):String{
if(cBox.data != null){
return artistlist.text;
}
return artistlist.text = "(artist = "+cBox.data+")";;
}
This registers the artist as 'undefined'. Am I going the right direction
here?
Thanks,
Tom.
----
Again, i'm sorry if im being repetitive here.