Can somebody point out what I am missing to bind the data from my form
into my data model? There does not seem to be any data in the
troubleEvent object when the save() function runs.
Code:
------
<?xml version="1.0" encoding="utf-8"?>
<mx:Panel
xmlns:mx="http://www.adobe.com/2006/mxml"
xmlns:Ctrl="Components.Controls.*"
layout="absolute"
top="10" left="10" right="10" bottom="10"
title="ITB Trouble Log">
<mx:Script>
<![CDATA[
import mx.controls.Alert;
import Model.troubleLog;
[Bindable]
protected var troubleEntry:troubleLog = new troubleLog;
protected function save(troubleEvent:Object):void
{
Alert.show('test "' + troubleEvent.application + '"');
parentApplication.troubleLogDAO.save(troubleEvent.application,troubleEvent);
}
]]>
</mx:Script>
<mx:VBox>
<mx:Form>
<mx:FormItem label="Application">
<mx:TextInput text="{troubleEntry.application}"/>
</mx:FormItem>
</mx:Form>
<mx:Button label="Submit" click="save(troubleEntry)"/>
</mx:VBox>
<mx:Button label="Trouble Log" right="10" top="10"
click="{parentApplication.troubleLog.selectedIndex=0}"/>
</mx:Panel>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Create Web Applications With ColdFusion MX7 & Flex 2.
Build powerful, scalable RIAs. Free Trial
http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJS
Archive: http://www.houseoffusion.com/groups/Flex/message.cfm/messageid:4286
Subscription: http://www.houseoffusion.com/groups/Flex/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.37