Setting up Flash Remoting with ColdFusion

/, Flash Remoting/Setting up Flash Remoting with ColdFusion

I would like very much to thank Eric Meyer from curious minds

for helping me figure this out`-` I had started to try to convert a actionscript 2 remoting app to actionscript 3, but got really confused towards the end. I saw a post on his blog, and he was nice enough to work with me over e-mail fixing all my confusion!

Check out his blog, lots of great information.

Setting up flash remoting with actionscript 3.0 and flash CS 3.
Create a fla, call it remoting(or something that makes sense to you).

In the actions, type the following code

var gateway:NetConnection = new NetConnection();

var responder:Responder=new Responder(onResult,onFault);

function onResult(responds:Object):void {

	trace("cfc result"+":"+" "+responds.toString());


function onFault(responds:Object):void {

	//loop over the fault structure

	for (var i:String in responds) {

		trace( i + ":" + responds[i] );



// name the default cf test server on this machine


// name of the cfc and the function in it that you want to hit in dot notation"com.cfcs.getTest.getTestConn", responder/*this is where any arguments to the remote call go*/);

The cfc lives on my localhost/com/cfcs/gettestConn.cfc

The cfc will look like this

<cfcomponent displayName="getTest">

  <!--- Establish a Flash Remoting Connection --->

  <cffunction name="getTestConn" access="remote" returnType="string" output="true">

    <cfreturn "....connection successful">



This is just the set up, and yep just returns the string from the cfc. Once set up, you can use remoting the way that it is meant to be used`-`

Any question, problems? Let me know I will try to help.

I will posting another example on how to display the results from your cfc, and later how to pull database results into your flash movie as well.

happy coding`-`

By | 2009-02-18T01:18:48+00:00 February 18th, 2009|ColdFusion, Flash Remoting|2 Comments

About the Author:


  1. Taiff April 1, 2009 at 2:20 am

    thanks john, it works, the function name is “getTestConn” and not “getTest”.

    i tried [“com.cfcs.getTestConn.getTestConn”, responder/*this is where any arguments to the remote call go*/);] it works.

    thank you 4 ur help.

  2. admin April 2, 2009 at 1:51 am

    glad you got it working, and I send you the code too.

    I would love to see your project when your done too.

    happy coding

Leave A Comment