Application data sample

This sample shows you how to store and retrieve data that is specific to each user and Windows Runtime app by using the Windows Runtime application data APIs (Windows.Storage.ApplicationData and so on).

 
 
 
 
 
4 Star
(20)
50,339 times
Add to favorites
4/2/2014
E-mail Twitter del.icio.us Digg Facebook
Sign in to ask a question


  • Roaming Settings
    6 Posts | Last post October 30, 2014
    • I'm trying to test Roaming Settings, using two machines of mine. It's not working. I installed the same package in both machines. One instance sets a value for a setting and the other never gets it. Both are connected with the same Windows Live ID and both are connected to the internet. There is a handler for DataChanged event.
      
      Did anyone ever make it work in a real environment?
      
      Thanks in advance!
    • Same Issue here. Did you find a solution? Maybe we need to associate the app with the store (Visual Studio -> Project -> Store -> ...) but this does not work for me right now...
    • Same here, any ideas?
    • In my case, the synchronization of the roaming data took around 5-15 minutes to take effect. The guidance for roaming data states that "Windows roams app data opportunistically and doesn't guarantee an instant sync" (see http://msdn.microsoft.com/en-us/library/windows/apps/hh465094.aspx), so I assume that the synchronization time is non-deterministic. Repeat the scenario, but this time wait some minutes for the synchronization to happen (you can use the 'HighPriority' setting that it's supposed to roam within a minute of being changed, see http://msdn.microsoft.com/en-us/library/windows/apps/windows.storage.applicationdata.roamingsettings) 
    • I have the same problem. Do you have any solution ? 
    • Hi:
      Did anyone find a solution to this? I am even trying to run the Windows phone sample and the Windows sample on the same computer. I ran them and kept them running for over 30 minutes and even the "roaming: high priority" counter didn't sync. 
      
  • Settings.settings globals
    1 Posts | Last post September 14, 2014
    • For a long time Settings.settings was created by VS and used to load settings on launch, and save settings before exit. It was handled in App.xaml.cs
      
      That is now gone in Store apps.
      
      What replaces it.  These would be the 'default' settings needed for first run, and need to be data bound to initialize a view.
      
      
      
  • Sample won't open in Visual Studio 2012 Professional
    1 Posts | Last post June 30, 2013
    • When I try to open up the ApplicationDataSample.sln I get an error from Visual Studio 2012 Professional that this project is incompatible with my version of Visual Studio.
      Strange.
  • C++ Sample is not working.
    2 Posts | Last post April 23, 2013
    • I am trying to compile and run, C++ sample, It is throwing an exception, and is not even getting able to navigate from splash screen logo to any screen, I am getting following exception:
      
      First-chance exception at 0x7487277C in ApplicationDataSample.exe: Microsoft C++ exception: Platform::COMException ^ at memory location 0x02F7D63C. HRESULT:0x80070002
      
      If there is a handler for this exception, the program may be safely continued.
      
      Please help.
    • me too..
  • Saving state while suspending and resuming
    1 Posts | Last post October 26, 2012
    • I tried to save the content of my app in current_suspending handler and loaded the content in current_resuming handler.This works absolutely fine. But if I suspend and resume my app more than once there is an exception on the line:
      save= await FileIO.ReadTextAsync(file);
      
      
      System.UnauthorizedAccessException was unhandled by user code
        
        HResult=-2147024891
        Message=Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
        Source=mscorlib
        StackTrace:
             at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
             at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
             at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
             at completing_the_SQUARE.MainPage.<Current_Resuming>d__0.MoveNext() in c:\Users\Sanchit\Documents\Visual Studio 2012\Projects\completing the SQUARE\completing the SQUARE\MainPage.xaml.cs:line 276
        InnerException: 
      
      
      However if I add a break statement on the above mentioned statement the code works perfectly. Have I done something wrong or is this an issue with VS12.
      
      Thanx in advance!