MACROMEDIA FLASH MEDIA SERVER 2-SERVER-SIDE ACTIONSCRIPT LANGUAGE Reference page 137

Server-side actionscript language reference
Table of Contents

Advertisement

Example
The following example calls the
method to execute the
SharedObject.send()
method in the client-side ActionScript and passes
the string
doSomething()
doSomething()
:
"this is a test"
var myShared = SharedObject.get("foo", true);
myShared.send("doSomething", "this is a test");
The following example is the client-side ActionScript code that defines the
doSomething
method:
connection = new NetConnection();
connection.connect("rtmp://www.macromedia.com/someApp");
var x = SharedObject.getRemote("foo", connection.uri, true);
x.connect(connection);
x.doSomething = function(str) {
// Process the str object.
};
SharedObject.setProperty()
Availability
Flash Communication Server MX 1.0.
Usage
mySO.setProperty(name, value)
Parameters
The name of the property in the shared object.
name
An ActionScript object associated with the property, or
to delete the property.
value
null
Returns
Nothing.
Description
Method; updates the value of a property in a shared object.
The
parameter on the server side is the same as an attribute of the
property on the
name
data
client side. For example, the following two lines of code are equivalent; the first line is server-
side ActionScript, and the second is client-side ActionScript:
mySO.setProperty(nameVal, "foo");
clientSO.data[nameVal] = "foo";
SharedObject class
137

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MEDIA SERVER 2-SERVER-SIDE ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash media server 2

Table of Contents