4 Replies Latest reply on May 18, 2009 2:22 PM by Peter Farland

    AIR to CFC with RemoteObject


      I am having problems accessing a CFC on my local ColdFusion server from an AIR application.  I keep getting an error that I cannot connect to http://localhost:8501/flex2gateway/


      I know my CF8 server is running.  I have already enabled Flash remoting in the CF admin console.


      Here's my application MXML file, which is located in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\Test2\src:


      <?xml version="1.0" encoding="utf-8"?>
      <mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="init()">
              import mx.rpc.events.FaultEvent;
              import mx.rpc.AsyncToken;
              import mx.controls.Alert;
              import mx.rpc.events.ResultEvent;
              private function init():void
                  var token:AsyncToken = service.getdata();
                  token.addResponder(new mx.rpc.Responder(resultHandler, faultHandler));
              private function resultHandler(result:ResultEvent):void
              private function faultHandler(fault:FaultEvent):void

      <mx:RemoteObject id="service"


      Here's my CFC which is C:\ColdFusion8\wwwroot\Test1\messageService.cfc


      <cffunction name="getdata" access="remote" returntype="string">
      <cfreturn "this is the return message">