开发者

Accessing shared object data without reloading swf – Is this possible?

I'm wondering if it's possible to access a shared object's data (once it's been changed) without reloading the swf. Specifically, I have two swfs: one changes the data in the so and lets the second swf "know" via a localconnection. I have a function in the second swf that fires via the local connection. The function below:

function getNewValue():void{
    totalOrderSO = SharedObject.getLocal("orderTotal", "/");
    test_txt.text = (totalOrderSO.data.subtot开发者_StackOverflow中文版alArray.length).toString();
}

This function looks for the new value however it doesn't show the updated value in my textfield unless I refresh the browser. Thoughts?


after addign values to the SahredObject you should call the flush() methode to make sure that the data has been added

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜