By Nimisha



10 December 2012

With AIR 3.5 the path of shared objects changed than what it used to be in AIR 3.4. The difference between the paths is discussed below:

In AIR 3.4:

AppName/Library/Application Support/ Store/ #SharedObjects/Filename.swf

where Filename.swf comes from the <Filenametag of app-xml.
In AIR 3.5:
AppName/Library/Application Support/ Store/ #SharedObjects/Content.swf

where Content.swf comes from the <Content> tag of app-xml which contains the name of root SWF of app.
This issue is fixed in 3.6(labs). When user updates his/her app from AIR 3.4 to 3.6, the application will not lose any data that is stored with shared object. Any new App that is published with the next release of AIR has the shared object path:
AppName/Library/Application Support/ Store/ #SharedObjects/Content.swf


Workaround for AIR 3.5

A workaround is available for the app-developers who are going to publish their app with AIR 3.5. Now shared object path is taken from tag <Content> rather than tag <Filename>, you can rename your root SWF to Filename.swf and provide the same to tag.
For example:
In AIR 3.4:

<Filename>MysharedObject</Filename> <Content>Root.swf</Content>

In AIR 3.5, rename it like following:

<Filename>MysharedObject</Filename> <Content>MysharedObject.swf</Content>

and also rename Root.swf  to MysharedObject.swf.
In this way the data of the app is saved when it is updated from AIR 3.4 to AIR 3.5.