David, Thatâs actually not correct. Flex remoting works in the same way as a normal cfm. You have full access to application and session scoping even if you just directly access a cfc.
Paul -----Original Message----- From: David Henry [mailto:[email protected]] Sent: Friday, February 20, 2009 5:13 PM To: flex Subject: Re: CFCs called from Flex are not seeing APPLICAT ION, SESSION, or other shared-scope va riablesââ¬Â Jordan, Someone correct me if I'm wrong. I think calling a cfc directly will bypass the Application.cfm or Application.cfc file. This means there is no context for the application or session scope because the cfapplication tag was probably skipped. Hope that helps, David Jordan Farr wrote: > Hello all, > > When I call my CFCs (CF8) using CFML from a CFM page, I can access > APPLICATION and SESSION variables no problem (i.e. the CFC is aware that it > is part of a given application that has some session variables). However, a > Flash movie built with Flex 3, sitting on the same CFM page as my working > CFML code, calling the same CFC as my CFML code, does not work because it > says that variables APPLICATION, SESSION, etc are undefined. > > I am not sure how to fix this issue. > > I know the CFC is accessible from the Flash movie because if I change the CFC > code to return a string "Hello World!" and ask the Flash movie to > Alert.show() it, it shows "Hello World!", so the lines of communications are > open. It is as if when a CFC is called via Flash remoting from Flex (I'm > using Remote Objects in Flex), the CFC doesn't know it is part of an > Application instance and instead acts statically. > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;207172674;29440083;f Archive: http://www.houseoffusion.com/groups/flex/message.cfm/messageid:5784 Subscription: http://www.houseoffusion.com/groups/flex/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.37
