[Red5] How to persist the sharedobject that it will not be destroyed after I reconnect to it?
wishsand(TOM)
wishsand at tom.com
Wed Mar 7 03:10:24 EST 2007
Dear folks:
Each time I getRemote, the sharedobject is renewed and I can't read the "history" from it.
//The code is:
soChat = SharedObject.getRemote( "ChatHistory", nc.uri, true );
soChat.addEventListener( NetStatusEvent.NET_STATUS, netStatusHandler );
soChat.addEventListener( AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler );
soChat.addEventListener( SyncEvent.SYNC, sharedObjectSyncHandler );
soChat.client = this;
soChat.connect(nc);
txtChatBox.text=String(soChat.data.history);
//When I send the msg, the "history" is set. It should have been stored in the sharedobject and have been read once more. However, it isn't.
soChat.size is always 0 when reconnect.
What's wrong with it?
Thanks!
Sand
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://osflash.org/pipermail/red5_osflash.org/attachments/20070307/ba951008/attachment.htm
More information about the Red5
mailing list