简体   繁体   English

如何使用此IsolatedStorageFile isoStore = IsolatedStorageFile.GetUserStoreForApplication(); 在WP 8.1中

[英]how to use this IsolatedStorageFile isoStore = IsolatedStorageFile.GetUserStoreForApplication(); in WP 8.1

IsolatedStorageFile isoStore = IsolatedStorageFile.GetUserStoreForApplication();

I had modified this as Storage File isoStore=StorageFile.________________(); 我已经将其修改为存储文件isoStore=StorageFile.________________(); but I can't find a method like GetUserStoreForApplication in Windows Phone 8.1. 但我在Windows Phone 8.1中找不到类似GetUserStoreForApplication的方法。 How to get this done? 如何做到这一点?

You can get the local storage folder with ApplicationData.LocalFolder or the roaming folder with ApplicationData.RoamingFolder. 您可以使用ApplicationData.LocalFolder获得本地存储文件夹,或者通过ApplicationData.RoamingFolder获得漫游文件夹。

Windows.Storage.StorageFolder localFolder = Windows.Storage.ApplicationData.Current.LocalFolder;
Windows.Storage.StorageFolder roamingFolder = Windows.Storage.ApplicationData.Current.RoamingFolder;

See Accessing app data with the Windows Runtime (Windows Runtime apps) for more info on using application data and settings. 有关使用应用程序数据和设置的更多信息,请参见使用Windows Runtime访问应用程序数据(Windows Runtime应用程序)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM