I am populating a combo box with a remote call to a
coldfusion component.
The combo box populates, however, when I submit the form I
cannot get any value.
I created a alert box to display the value of the combo box
however it will not show up with the value the the CB.
Here is a summary of the code:
Remote Call:
<mx:RemoteObject id="myService" destination="ColdFusion"
fault="Alert.show(event.fault.faultString), 'Error'"
source="ACIT.formSend">
<mx:method name="getStates"
result="getStatesResult(event)" />
</mx:RemoteObject>
private function init(eventObj:Event):void {
//get the state data
myService.getStates();
}
private function getStatesResult(event:ResultEvent):void{
applicant_state.dataProvider = event.result as
ArrayCollection;
}
Function that has the alert box when the form is submitted:
private function insertAction():void
{
Alert.show(applicant_state.selectedItem.data.toString());
}
--------------------------------------
here is my combo box:
<mx:ComboBox x="406" y="159" id="applicant_state"
labelField="state" width="200" fontFamily="Arial" fontSize="12"
color="#000000" fillColors="[#0080c0, #0080c0]" prompt="Select
State"></mx:ComboBox>
Any Help or guidance is appreciated.
Thanks.
Ron