windows-runtimewindows-phonewindows-phone-8.1windows-phone-sl-8.1

Windows Runtime Component with Windows Phone Silverlight 8.1


I have an existing Windows Phone 8 app which is basically an alarm app. For whatever reason, Alarm class is not supported by the new Windows Phone RunTime, so going forward I can only upgrade it to Windows Phone Silverlight 8.1.

Luckily WP SL 8.1 project is still able to reference Windows RunTime Component as my goal is to use some of the cool features in the new Background Task mechanisms.

And here comes my problem -

My app currently uses Isolated Storage to store the data, while it's not in the foreground, its Background Task project needs to retrieve the data from Isolated Storage and display them onto the live tile. However, as this project is a Windows RunTime Component, it doesn't support Isolated Storage anymore...

So, I hate to ask but, am I hitting a dead end?


Solution

  • All Windows Phone 8.1 apps (Silverlight or Windows Runtime) share a common folder structure on disk and any data that was previously written using the IsolatedStorage APIs has been migrated into the location accessible via Windows.Storage.ApplicationData.Current.LocalFolder. So while the IsolatedStorage types are not available from Windows Runtime background tasks, the data is still there.

    Functions for reading and extracting the information can be found on msdn.