Ok this is so weird...

I have got both cfcs in different directories underneath the cf
webroot directory 

remoting (working) - C:\CFusionMX7\wwwroot\remoting\samples
ppd (not working) - C:\CFusionMX7\wwwroot\ppd\components

I call the cfc's from my flex app like this (i am not using named RO's
any more)...

<mx:RemoteObject 
  id="miscCFC"
  endpoint="http://localhost:8500/flashservices/gateway";
  source="remoting.samples.miscTables"
  fault="doFault(event)"
  showBusyCursor="true">
</mx:RemoteObject>

In the cf gateway-config.xml file (C:\CFusionMX7\wwwroot\WEB-INF\) i
have the following code inside
the "<gateway-config><security><whitelist><named>" element (to allow
access to my components)...

    <object name="misc">
      <source>remoting.samples.miscTables</source>
    </object>
                                
    <object name="misc2">
      <source>ppd.components.miscTables</source>
    </object>

Inside the Flex flex-config.xml file
(C:\Flex\jrun4\servers\default\ppddev\WEB-INF\flex\) i have the following 
code inside the "<flex-config><remote-objects><whitelist><named>"
element (to bypass the bug Flex 1.5 has)...

    <object name="misc">
      <source>foo.bar3</source>
    </object>

    <object name="misc2">
      <source>foo.bar5</source>
    </object>

I decided to install the cf and Flex servers on my laptop as i need to
do get some development done while im on the road.
I have changed the flex config file to allow this.
Flex's flash gateway now points to the cf flash remoting gateway
<amf-gateway>http://localhost:8500/flashservices/gateway</amf-gateway>

I have a crossdomain.xml document in the wwwroot of the cf server
which contains the following code...

    <cross-domain-policy>
      <allow-access-from domain="*" />
    </cross-domain-policy>

Is this the crossdomain policy file you are talking about (is this
what is needed?)

I dont think this is really relevant at the minute as i am running
both my cf/flex servers locally (but might come in 
useful when i deploy the system for use in the real world!)

When you say about using the servername in the connection URL, i dont
think i am having any problems with this at the 
minute as the remoting cfc is working fine, its just the ppd cfc
doesnt seem to want to play!

I was also wondering if you had any idea about merging cf/flex so that
i can have just one JRun instance that will serve
up cfm pages (this is what the main system runs on) with mxml embedded
within them.  Also, is there a way to compile the mxml
files to flash files (.swf) so that i can just embed the flash file,
or is this even necessary?

I hope this is enough information, im not sure what else to tell you,
if you need any more info let me know...
i think i could have written my whole flex by the time i got the info
for this post lol

Thanks for all your help (and sorry for the long post!!!)

Barry

--- In flexcoders@yahoogroups.com, "Dekayd Media Inc." <[EMAIL PROTECTED]> 
wrote:
>
> Is your main CFC directory under your webroot or is it setup in the CF
> Admin?
> 
> Did you setup a crossdomain policy file on your coldfusion instance?
> 
> If your cfc's are on your server then you should be using your
servername in
> the connection URL or a domain name if you have one pointed at that
server.
> 
> 
> 
> --Kelly
> 
> 
> 
> 
> 
> 
> 
> -----Original Message-----
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of oiland_barry
> Sent: Monday, February 27, 2006 8:11 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Coldfusion cfc's and Flex Remote Objects
> 
> Hi,
> 
> i have successfully got this working (almost!) at long last. I am
> running both my cf and flex as iintegrated JRun servers on my server
> machine (port 8700 and 8500 respectively) and i am developing and
> accessing the mxml files from my laptop.
> 
> I can get the echo cfc to work ok, and i also placed another cfc in
> the same directory (plants.cfc) which seems to let me get flex and cf
> communicating.
> 
> My problem is that when i try to use another cfc in another directory
> (not \flex\remoting\samples\) flex doesnt seem to be able to
> communicate at all, it just sits there with the busy symbol.
> 
> Im not sure whats going on, but i am sure that i have added the
> appropriate code in the right places and all the configuration files
> (flex's flex-config.xml, cf's gateway-config.xml) seem to be in order!
> 
> Its just not working at all and i cant continue developing until i can
> reliably have access to the cfc's!
> 
> Also, the named remote objects are giving em a bit of trouble...
> should i be pointing to the server name or localhost. When i use
> localhost, flex doesnt seem to be able to talk to the cfc's, but when
> i use the servers name (advent) it seems to work fine.
> 
> Basically i cant get my flex to talk to my cfc's when they are stored
> in my main cfc directory. I have restarted both the cf and flex
> servers on many occasions and i have also restarted the whole machine
> on a few occasions just to be sure everything is initialised properly.
> I'll give it another restart now just to see.
> 
> Please help,
> 
> Barry
> 
> 
> 
> 
> 
> 
> --
> 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
>





--
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/

<*> 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