I made a small app to try out. Just a datagrid that should get populated from data from my db. I went through tons of posts and sites and finally figured out how to get it all together. Now when I run it, I get no error and no data. In debug the result is ânullâ. This CFC does work in my CF app. I had someone that know flex look it over and he said all the code is correct and it should work. One thing I did notice is that I donât believe the function in the CFC is even getting called as I had put a cflog entry in it and it never got written to. But it does validate that I am in the correct CFC and function because if I change either of those names, it throws an error.
Details of the install are as follows: CF 8.01 developer edition Flex builder 3 Flash remoting option and CF selected in Flex project Flash remoting enabled in CF admin Vista Home Premium and using IIS I can get to the flex2gateway no problem Here is my flex code: <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="initApp()" viewSourceURL="srcview/index.html"> <mx:DateFormatter id="dateFormatter" formatString="mm/dd/yyyy"/> <mx:Script> <![CDATA[ import mx.collections.ArrayCollection; import mx.rpc.events.ResultEvent; [Bindable] private var qResult:ArrayCollection; private function initApp():void { ResultRequest_RO.AdvancedSearch(); } private function ResultRequestRO_Handler(e:Object):void { //dgSearchRequest.dataProvider = e.result; qResult = e.result as ArrayCollection; } ]]> </mx:Script> <mx:RemoteObject destination="ColdFusion" source="com.wucf.search" id="ResultRequest_RO" showBusyCursor="true"> <mx:method name="AdvancedSearch" result="ResultRequestRO_Handler(event)" fault="mx.controls.Alert.show(event.fault.faultString)"/> </mx:RemoteObject> <mx:DataGrid right="10" left="10" top="10" bottom="10" dataProvider="{qResult}"> <mx:columns> <mx:DataGridColumn headerText="Company" dataField="comp_name"/> <mx:DataGridColumn headerText="City" dataField="comp_city"/> <mx:DataGridColumn headerText="State/Prov" dataField="comp_state"/> <mx:DataGridColumn headerText="Country" dataField="comp_country"/> <mx:DataGridColumn headerText="Added On" dataField="dateFormatter.format(date_added)"/> </mx:columns> </mx:DataGrid> </mx:Application> If anyone can shed some light on this, that would be great so I can continue to learn Flex. If more info is needed, please let me know. Thanks, Derek ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;192386516;25150098;k Archive: http://www.houseoffusion.com/groups/Flex/message.cfm/messageid:5285 Subscription: http://www.houseoffusion.com/groups/Flex/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.37
