I posted this on a different thread earlier but the site isn't showing it (maybe because of the attachment) so here it goes again.
---- Remoting is quite simple but it has be convoluted with a million different ways of doing it. Download the zip file<http://blogs.katapultmedia.com/jb2/assets/resources/km.zip>; has 1 custom class that will handle everything for you. Here is how you use it. 1) Extract the file (keep the current path structure [km/connection/Remoting.as] or simply rename the class 2) Use the following AS: import km.connection.Remoting; import mx.utils.Delegate; //path to your gateway Remoting.instance.gateway = "http://www.mysite.com/flashservices/gateway "; //path to your cfc's from your site root Remoting.instance.package = "assets.cfcs."; //don't forget the final period function myResult(result){ //here is your result } function myFault(fault){ //here is your fault } //make a call to your test.cfc's helloWorld function Remoting.instance.trigger("test.helloWorld", Delegate.create(this, myResult), Delegate.create(this, myFault)); //pass a string to your echo.cfc 's sayThis function Remoting.instance.trigger("echo.sayThis", Delegate.create(this, myResult), Delegate.create(this, myFault), "My name is Andy."); That will do it for you. The Delegate class is used for scoping purposes. You can have as many result or fault functions as you would like. This class isn't done 100% but it gets the job done. I've used it on a couple projects (Remoting + CF and Remoting + PHP) with no probs @ all. Make sure you have the Remoting components/classes installed ( http://www.macromedia.com/go/flashremoting). Hope this helps.... On 2/23/06, Andy Matthews <[EMAIL PROTECTED]> wrote: > > I have Flash 8 and I'd prefer to use remoting but I don't know how.. I've > looked for tutes on Flash remoting but can't find anything > straight-forward. > > Do you have any links you'd care to share with the class? > > <!----------------//------ > andy matthews > web developer > ICGLink, Inc. > [EMAIL PROTECTED] > 615.370.1530 x737 > --------------//---------> > > -----Original Message----- > From: Kevin Aebig [mailto:[EMAIL PROTECTED] > Sent: Thursday, February 23, 2006 3:49 PM > To: CF-Talk > Subject: RE: Getting data into Flash 8 > > > Here's an even better idea. Why not use a CFC and use Flash remoting to > get > the data. It's way more clean... > > What version of Flash and CF are you using? > > !K > > -----Original Message----- > From: Andy Matthews [mailto:[EMAIL PROTECTED] > Sent: February 23, 2006 2:18 PM > To: CF-Talk > Subject: Getting data into Flash 8 > > I'm getting so freaking pissed at Flash and at Macromedia I can't see > straight. > > I don't want to be one of those people who complains about changes in > programs but for God's sake Macromedia/Adobe leave something alone for at > LEAST one version! > > That's my rant, but here's my problem. I'm trying to pass data into Flash > by > calling a coldfusion page. That CF page returns this string: > > ?someVar0=Matt Dusk&someVar1=The Monkees&someVar2=Tantric&someVar3=Clay > Walker&someVar4=ESPN&someVar5=EMI-Sparrow&someVar6=Columbia > Pictures&someVar7=Verity/Zomba&someVar8=Dexter Green&someVar9=John > Jaszcz&someVar10=Mark Wright&someVar11=Kurt Carr > > The code in Flash which calls this page looks like this (copied from the > Intertron): > > var myNames:LoadVars = new LoadVars(); > myNames.onLoad = function(success:Boolean) { > if (success) { > var idArray = []; > for (i=0; i<12; i++) { > trace(_root.someVar5); > idArray.push(eval("_root.someVar"+i)); > } > } > }; > myNames.sendAndLoad("getNames.cfm", myNames, "POST"); > > I'm trying to put each of the variables from the data string into an Array > so that I can loop over that array later in the code. That final part of > the > code already works, but I need a valid array that can be fed to it. > > Can someone tell me what I'm doing wrong? > > <!----------------//------ > andy matthews > web developer > ICGLink, Inc. > [EMAIL PROTECTED] > 615.370.1530 x737 > --------------//---------> > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:233301 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

