Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

How to: Find the Space in Isolated Storage in Windows Phone

DZone's Guide to

How to: Find the Space in Isolated Storage in Windows Phone

· Mobile Zone
Free Resource

Download this comprehensive Mobile Testing Reference Guide to help prioritize which mobile devices and OSs to test against, brought to you in partnership with Sauce Labs.

The IsolatedStorageFile class in Windows Phone provides the methods that indicate the amount of space (free/total space) for isolated storage.

The IsolatedStorageFile class has the following members which could be used to find out the space related information for isolated storage.

1. Quota – This property will return the maximum amount of space available for the isolated storage.

2. AvailableFreeSpace – This property will return the available space for isolated storage.

decimal availablespace, Quota;
using (var store = IsolatedStorageFile.GetUserStoreForApplication())
{
   availablespace = store.AvailableFreeSpace ;
   Quota = store.Quota ;
}

MessageBox.Show("Available : " + availablespace.ToString() + ",Quota : " + Quota.ToString())

Analysts agree that a mix of emulators/simulators and real devices are necessary to optimize your mobile app testing - learn more in this white paper, brought to you in partnership with Sauce Labs.

Topics:

Published at DZone with permission of Senthil Kumar, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}