1 Reply Latest reply on Jul 1, 2011 2:55 PM by Marstano

    Problem retrieving Session variables in Flex from Coldfusion


      For about a year I've been using a cfc that allows me to remote call from within Flex to retrieve session-level variables.  I much prefer this to using FlashVars because with the remote call the session values don't show up in the page source.


      This was working fine when I was using an Application.cfm file to manage my Coldfusion pages.  However when I switched to using an Application.cfc file, the cfc stopped working.  Neither the cfc or the cfm file contain any code to manage these session variables (they are set in other pages), so the only real difference seems to be changing from Application.cfm to Application.cfc.


      Any thoughts why?  Thanks.

        • 1. Re: Problem retrieving Session variables in Flex from Coldfusion
          Marstano Level 1

          Ok, this is resolved.


          The problem seems to have been related to the scope of Application.cfc and Application.cfm.  The directory which contained the cfc files had an Application.cfm controlling the session, while the directory with the pages that included the flex swf files had an Application.cfc file.  Apparently these two don't talk to each other.


          The solution is to use either Application.cfc or Application.cfm files, but not to mix them.  In other words, use either -- but be consistent.