[Windows Phone 7 Development and Hacking] hx4700 Killer:
[APP] Working App to Backup Windows Phone 7 via ZUNE ANY TIME

I posted this in windows phone 7 apps and it was suggested that I post it here so don't hammer me for cross posting please.

I have written a .Net app for backing up windows phone 7 via the Zune updater tool. This backup can be used by Zune to restore the device when you use the "Update" option under settings.

Firstly I have to credit this to reading and putting together pieces from several threads on XDA. I read so many to be honest I am no longer sure who all to credit. There was no specific single source I just saw several things and through trial and error put together the pieces that made this possible.

This APP is a wrapper around a tool microsoft produced to perform updates to your phone via command line. Specifically the executeable "updatewp.exe" that comes from the Windows Phone Support Tools. The missing piece that eluded me for a bit was the update package itself which I found here on XDA and will link to later.

Prerequisites that need to installed/downloaded:

Zune Software Installed: http://www.zune.net/en-us/products/software/download/default.htm

Windows Phone Support Tools Installed:

x64 Windows: http://download.microsoft.com/downl...E4A-8179-9A3C5483E366/WPSupportTool-amd64.msi

x86: http://download.microsoft.com/downl...-4E4A-8179-9A3C5483E366/WPSupportTool-x86.msi

An update package from ANY phone, this one is for an HD2 that I used while working on a samsung focus. Download and Unzip:

http://xdaforums.com/showpost.php?p=11542700&postcount=6

If you are missing these prerequisites the app will tell you and even open a web page on request to the DL links.

Please understand this is release 1.0 and as such may have issues depending on your platform and your computer etc.... I coded it for x86 and x64 Windows with the Microsoft .net Framework 2.0 minimum. I tried to consider several error scenarios but one never knows how an end user might use your program that wasnt anticipated and coded for.

If an error occurs you should find the text in your clipboard for easy pasting here on the forums.

To explain the process:

updatewp.exe is meant to update your phone with PKS files theoretically obtained from the device manufacturer. It will also do other things including a command line restore of a backup.

This program launches updatewp.exe with two command line arguments. One is the PKS file name and path and the second is the enablebackup switch.

What happens is the phone performs the backup first, once it completes the process the code terminates updatewp.exe before it goes further. In theory if you are using an update not compatible for your phone it would actually just say that and quit. However terminating the updater keeps it from ever getting that far.

I have used this to make a complete backup AND restore it via the ZUNE Update options under settings for my phone so I know it works.

One could most likely also archive backups by copying/moving from their storage point before creating a new one so as to have a backup that could be reverted to from a point in time further than the last one on record. If there is enough interest in such a feature and incentive I would consider adding it here.

Attached to this post is a zip file with two folders. x86 and x64. Please launch the appropriate EXE for your platform.

If you do not have zune or windows phone support tools it will tell you immediately and offer to open the download URL on your computer.

If you pass those tests you will need to input a path to the PKS file in the long textbox. There is a button just above it that will open a URL to the download for the one I used here on XDA. There is also a Browse button below the textbox for you to use to browse to and set the file path via GUI.

Once the path is set click on backup and watch it go. If you already have a backup made previously this will overwrite it.

I can not say if this will work with a debranded phone but I don't see why not. My focus is an out of the box stock AT&T phone with chevron unlock on it (which you shouldnt need) and a couple of non-marketplace apps.

Good luck and post feedback, thoughts or issues please.

***Adding Instructions on how to restore as its come up a few times:

Make sure your phone is hooked up to the computer first then from within the ZUNE software you should see a menu near the top right-hand side labeled "Settings". Click on that. On the settings screen look near the top left and you should see "Software" "Device" and "Account". Instead of device it may say "Phone".

Click on Device or Phone, whichever you see. The left edge has several options. Near the middle you should see "Update". Click that. You should see a progress bar for a few seconds and then most likely it will tell you that the phone is up to date. At the BOTTOM of all the text it spits out should be a button labeled "Restore" with the date of the backup.

You CAN'T change the memory size and perform a restore, I already know this doesnt work.