Gavin Draper's Blog

Father, Developer, Tech Geek, Extreme Sports Fanatic

@gavdraper | +gavdraper | github | StackOverflow Careers
 

Debugging WP7s Isolated Storage

As part of the Windows Phone SDK you get the IsolatedStorageExplorerTool, this tool allows you to explore and update what is in the current applications Isolated Storage.

The IsolatedStorageExplorerTool is installed in a path something like…

“Program Files\Microsoft SDKs\Windows Phone\v7.1\Tools\IsolatedStorageExplorerTool”

The first thing you need to do is get the Product ID for your application, you can get this by opening WMAppManifest.xml under properties folder in your WP7 project.

WP7ProductId

Once you have this….

To get a directory listing

To get a directory listing from the root…

  1. Open a command window and navigate to your IsolatedStorageExplorerTools directory
  2. Run one of the following commands
    1. If you are debugging in the emulator : ISETool.exe dir xd YOUR-PRODUCTID
    2. If you are debugging with a device : ISETool.exe dir de PRODUCTID

To get a directory listing from a specific directory….

    1. From emulator : ISETool.exe dir:FolderName xd YOUR-PRODUCTID
    2. From device : ISETool.exe dir:FolderName de YOUR-PRODUCTID

As you have probably guessed the xd switch means get the storage from the emulator and the de switch means get it from an actual device.

To copy the contents of Isolated Storage to your computer

The following command will copy the entire contents of your applications Isolated Storage to c:\temp\myapp …

ISETool.exe ts xd YOUR-PRODUCTID "C:\temp\myapp"

As before swap xd for de if you are running on an actual device rather than an emulator.

To replace a file in Isolated Storage

Once you have copied the contents of Isolated Storage to your computer you can then make changes to those files and copy them back over to Isolated Storage. Lets assume you copied the files to c:\temp\myapp in the step above, if you have then made changes to one or more of the files you copied across you can copy the changes back in to Isolated Storage by running the following command…

ISETool.exe rs xd YOUR-PRODUCTID "C:\temp\myapp"


 
comments powered by Disqus