Irina --

Thanks for the suggestion, but I'm not sure that's germaine.  I've
used other remote objects that are working just fine without a channel
definition.  This seems to be an issue of the object I'm passing from
Flex/ActionScript is not being well received by ColdFusion.  (Unless
I'm missing the fact that defining a channel would affect that in some
way?)

Al

--- In [email protected], "iviivi_us" <[EMAIL PROTECTED]> wrote:
>
> Hi Al,
> 
> It's seems to me you are missing channel definition, 
> something like
> 
> public var cSet:ChannelSet;
> 
> public function initApp()
> {
> cSet = new ChannelSet();
> var customChannel:Channel = new AMFChannel("my-cfamf", 
> http://localhost:8500/flex2gateway/);
> // Add the Channel to the ChannelSet. cSet.addChannel(customChannel);
> foo.channelSet = cSet;
> }
> 
> 
> <mx:RemoteObject 
> id="foo" 
> destination="ColdFusion" 
> source="com.foo.component" />
> 
> I took the code from Mike Nimer's Blog:
> http://www.mikenimer.com/index.cfm/2006/7/19/Flex-Data-Server-and-CF-
> Flash-Remoting-together
> 
> 
> Irina
> --- In [email protected], "foote3" <foote3@> wrote:
> >
> > I'm trying to pass an object back to a cfc via RemoteObject and 
> can't
> > get a favorable resolution, please look this over and let me know if
> > you see my error?
> > 
> > The error I am getting seems to imply that either the object is not
> > being sent or it's not arriving correctly. (How does ColdFusion
> > receive an object? Should I be using some other type (struct, array,
> > etc.)?)
> > 
> > Al
> > 
> > The object is a collection of name/value pairs and is defined.
> > 
> > This is the ActionScript part:
> > 
> > //this is the creation of the object
> > var eventTransfer:Object = modelEvent.transferObject;
> > 
> > public var svcEvent:RemoteObject = new RemoteObject();
> > public function useRemoteObject(eventTransfer:Object):void{
> > svcEvent.destination ="ColdFusion";
> > svcEvent.source = "EventComp";
> > svcEvent.qryEventData.addEventListener("result", resultHandler);
> > svcEvent.qryEventData.addEventListener("fault", faultHandler);
> > svcEvent.qryEventData(eventTransfer);
> > }
> > 
> > This is the CFC:
> > <cfcomponent name="EventComp">
> > 
> > <cffunction name="qryEventData" access="remote" returnType="query">
> > <cfargument name="eventTransfer" type="struct" required="yes"/>
> > <cfparam name="eventTransfer" type="any" default="not_passed"/>
> > 
> > <cfif eventTransfer is not "not_passed">
> > <cfset eventName = eventTransfer.eventName>
> > <cfset eventLocation = eventTransfer.eventLocation>
> > <cfset contactName = eventTransfer.contactName>
> > 
> > <cfquery datasource="Roster" name="newEvent" debug="yes">
> > INSERT INTO tblEvents
> > (eventName, eventLocation, contactName)
> > VALUES (#eventName#, #eventLocation#, #contactName#)
> > </cfquery>
> > </cfif>
> > <cfquery datasource="Roster" name="event" debug="yes">
> > SELECT * FROM tblEvents
> > </cfquery>
> > // this if statement is just so I can tell if the parameter is 
> really
> > passed or not.
> > <cfif eventTransfer is "not_passed">
> > <cfquery datasource="Roster" name="event" debug="yes">
> > SELECT * FROM tblEvents WHERE eventName = "NSCW"
> > </cfquery>
> > </cfif>
> > <cfreturn event>
> > </cffunction>
> > </cfcomponent>
> >
>







--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/flexcoders/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[EMAIL PROTECTED] 
    mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to