MACROMEDIA FLASH REMOTING MX-USING FLASH REMOTING FOR FLASH MX 2004 ACTIONSCRIPT 2.0 Use Manual page 38

Using flash remoting for flash mx 2004 actionscript 2.0
Table of Contents

Advertisement

You use the constructor for the Service class to create a new Service object. The following example
shows how to create a Service object (
connection ("
http://localhost:8300/flashservices/gateway
(
) to a remote service ("
custService
custService = new Service("http://localhost:8300/flashservices/gateway",
new Log(),
"CustomerInfo",
null,
null);
When you create a gateway connection in this manner, you can access the Connection object
through the
connection
class in Flash Remoting ActionScript Dictionary Help.
Specifying the gateway connection in a web page
You specify the gateway in the web page that loads your SWF file by adding entries in the
tag that calls the SWF file. You must use different techniques for Microsoft Internet Explorer and
Netscape Navigator browsers:
To specify the gateway for Internet Explorer, specify the gateway URL as a
parameter in an HTML
To specify the gateway for Netscape, specify the gateway URL as a
HTML
EMBED
The following HTML example runs the myMovie.swf Flash application and specifies http://apps.
myCompany.com/flashservices/gateway as the URL for the Flash Remoting services gateway. The
first highlighted line contains the code for Internet Explorer. The second highlighted line
contains the code for Netscape.
<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.
cab#version=6,0,0,0"
WIDTH="100%"
HEIGHT="100%"
id="MyMovie">
<PARAM NAME="flashvars" VALUE="gatewayUrl=http://apps.myCompany.com/
flashservices/gateway">
<PARAM NAME=movie VALUE="MyMovie.swf">
<PARAM NAME=quality VALUE="high">
<PARAM NAME=bgcolor VALUE="#000099">
<EMBED src="MyMovie.swf"
FLASHVARS="gatewayUrl=http://apps.mycompany.com/flashservices/gateway"
quality=high bgcolor="#000099"
WIDTH="100%"
HEIGHT="100%"
NAME="movieName"
TYPE="application/x-shockwave-flash"
PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">
</EMBED>
</OBJECT>
38
Chapter 2: Using Flash Remoting ActionScript
new Service()
CustomerInfo
property of the Service object. For more information, see the Service
tag inside the
PARAM
tag that specifies the Flash application.
) while simultaneously creating a gateway
") and a reference
"):
tag body.
OBJECT
flashvars
OBJECT
flashvars
attribute to the

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH REMOTING MX-USING FLASH REMOTING FOR FLASH MX 2004 ACTIONSCRIPT 2.0 and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash remoting mx

Table of Contents