XAP files are the modern version of the CAB files we used to have back in the Windows Mobile days. Basically, a XAP file is the complied installation file for a Silverlight application. Typically, you would never need to copy this to your device, as you would simply download the application directly from the marketplace. However, if you’ve been invited by a developer to help test their application, or you’re company has a custom built app that you need to load on your device, this is how you’ll do it.
The first thing you need to be aware of, is that not everyone can load an application on their device that doesn’t come from the marketplace. In order to do this, the first thing you need to do is developer unlock the device. There are a ways to do this – the only official way is to signup for Microsoft’s developer program and along with that you will get the ability to developer unlock a few devices. To do this, you’ll need to pay a $100 registration fee to Microsoft. You can learn more about this, and sign up over at Create.MSDN.com.
So now you have a developer unlocked device, and you have your XAP file. Next, you’ll need the Windows Phone SDK too kit. This will provide you with the development environment needed to create new applications. While you may not be creating your own application, we need this SDK installed so we can gain access to the deployment tool. You can find the tools over on here. Download and install the SDK on your computer.
Now that you have the Windows Phone SDK installed, we can deploy that application to your device. First, connect your Windows Phone to your computer and allow the Zune software to do it’s thing. Once the sync is done, close the Zune application. Click Start and type “Application Deployment” (if you’re running Windows 7, otherwise it’s located under Start / Programs / Windows Phone Developer Tools / Application Deployment).
You will now be presented with the window above. Simply browse and select your XAP file. Make sure the Target is set to “Windows Phone Device” and not to the emulator. Then unlock your device by sliding up the lockscreen and entering your password – if you have a device password. Once unlocked, press the Deploy button and the XAP will be transferred to the device and installed. And – Presto! You’re off and running with your custom app on Windows Phone.
I’ve run into a couple issues with this procedure. It seems that Microsoft has a few bugs lingering in the software. If you do have any weird errors, try and correct whatever the error says is wrong. Also, try disconnecting the device, and then connect it again and allow the sync process to finish before closing Zune and launching the deployment tool. Finally, make sure the device is logged in and sitting at the Today / home screen. Nothing major here – a little fiddling and you should be off to the races!




Recent Comments