SharedObject not updating between tabs

Just created an app which required persistent data, so used a local SharedObject. However discovered that if one person had the app open in two different places(eg. 2 tabs) the persistent data in one tab wasn’t updating in the other tab. To remedy this I tried reloading the SharedObject(SharedObject.getLocal) every time I extracted a variable, and yet this SharedObject variable still wasn’t updating.

Discovered that, strangely, the only way to update the SharedObject, is to first set it to null. Set it to null and then reload it forces an update.

Interactive developer, Author - iOS development with Swift - book coming 2017 https://manning.com/books/ios-development-with-swift

Tagged with:
Posted in Flash

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: