Using Flash Remoting Update
To specify a CFC to connect to, you do one of the following:
Specify the CFC, including the path from the web root, in the MXML.
■
Create a named resource for each CFC that you connect to. This is similar to registering a
■
data source.
To specify the CFC in the MXML:
Specify the CFC, including the path from the web root, in the MXML; for example:
■
<mx:RemoteObject
id="myCfc"
destination="ColdFusion"
source="myApplication.components.User"/>
The destination "ColdFusion" is preconfigured in the services-config.xml file, which is
located in the ColdFusion webroot\WEB-INF\flex directory, with the wildcard
source. To use the source attribute in MXML, you can use any destination by specifying
the
source="*".
the source specified in the MXML.
To create a named resource for each CFC that you connect to:
Edit the services-config.xml file by adding an entry for each CFC that you connect to, for
1.
example:
<destination id="CustomID">
<channels>
<channel ref="my-cfamf"/>
</channels>
<properties>
<source>dot_ path_to_CFC</source>
<lowercase-keys>true</lowercase-keys>
</properties>
</destination>
The
attribute specifies the dot notation to the CFC from the web root (the
source
classpath to the CFC).
Restart the ColdFusion server.
2.
6
Using Flash Remoting Update
If you specify a source other than "*", that source definition overrides
as the
*
Need help?
Do you have a question about the COLDFUSION MX 7.0.2-USING COLDFUSION MX WITH FLEX 2 and is the answer not in the manual?