| CraigFriebolin-YDxpq3io04c@public.gmane.org 2006-06-11, 7:11 pm |
|
I have an application where I'd like to store new client connects in a
shared object and be able to call them later. I've been trying to figure this out
for 2 days now!!!
Storing the info in shared object wasn't a problem but USING the information
is another story. The short version of the code is this...
application.onConnect = function(newClient, username) {
application.users_so.setProperty(username, newClient);
}
// USERNAME = Craig
newClient.SrvrMsg = function(USERNAME) {
application.users_so[USERNAME].call("Blah", null, stuff);
}
But no matter how I write:
application.users_so[USERNAME].call("Blah", null, stuff);
I almost always end up with an error: "ReferenceError: Craig is not defined"
I know this can be done with a 'regular' object like this;
application.onConnect = function(newClient, username) {
application.users[username] = newClient;
}
// USERNAME = Craig
newClient.SrvrMsg = function(USERNAME) {
application.users[USERNAME].call("Blah", null, stuff);
}
but for reasons to complicated to explain I need to make it work with a
shared object. If anyone can help me with this I would REALLY appreciate it!
Thanks in advance for any and all help with this!!
Craig
________________________________________
_______
FlashComm-1Ss2GqJETD3yZ38Mhd3e/9ZfFG6BLHNm@public.gmane.org
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
|