MACROMEDIA FLASH COMMUNICATION SERVER MX-SERVER-SIDE COMMUNICATION ACTIONSCRIPT DICTIONARY Manuale Utente Pagina 62

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 80
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 61
62
Parameters
methodName The name of a method on a client shared object instance. For example, if you
specify
doSomething, the client must invoke the SharedObject.doSomething method, with all
the p1, ..., pN parameters.
p1, ..., pN Parameters of any ActionScript type, including references to other ActionScript
objects. These parameters are passed to the specified methodName when it executes on the Flash
client.
Returns
A Boolean value of true if the message was sent to the client; false otherwise.
Description
Method; executes a method in a client-side script. You can use SharedObject.send to
asynchronously execute a method on all the Flash clients subscribing to a shared object. The
server does not receive any notification from the client on the success, failure, or return value in
response to this message.
Example
This example calls the SharedObject.send method to execute the doSomething method in the
client-side ActionScript and passes
doSomething the string "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
};
SharedObject.setProperty
Availability
Flash Communication Server MX.
Usage
sharedInfo.setProperty(name, value);
Parameters
name The name of the property in the shared object.
value An ActionScript object associated with the property, or null to delete the property.
Returns
Nothing.
Vedere la pagina 61
1 2 ... 57 58 59 60 61 62 63 64 65 66 67 ... 79 80

Commenti su questo manuale

Nessun commento