How to Deploy XAP File in a Windows Phone Emulator?


This post is with response to a question asked by my friend Abhimanyu. Yesterday he asked me whether it is possible to test the Windows Phone app on computer by installing in emulators?

 

I answered him personally but thought to write a post on the same with proper steps so that, if you want to deploy any Windows Phone XAP file in your emulator to test it, this post will guide you.

 

Problem Statement

Many question has a single problem and we will cover all the questions related to it in a single problem statement. Today in this post we will cover the following scenarios:

    • If I don’t have physical Windows Phone device and want to test a XAP received from my friend, will I be able to test it?
    • Is it possible to deploy a Windows Phone XAP file in an emulator and test it from there?
    • How to deploy a XAP file in a Windows Phone emulator that comes with WP SDK?
    • What are the issues that one will face while testing a XAP from emulator?

 

Solution

Ok, let’s begin with the above mentioned questions one by one. Yes, if we don’t have a physical windows phone device, we can test any XAP file but for this we need the Windows Phone Emulator which comes with the SDK tool. For this, you must have to install the Windows Phone SDK Tool which you can get it from here.

 

If you already installed the SDK, you will also have the emulator installed in your computer. The Windows Phone SDK comes with an utility named “Application Deployment” which you can find from Start menu program folder named “Windows Phone SDK 7.1”. Here is the screenshot of the same:

 

Start Windows Phone Application Deployment Tool

 

Click the “Application Deployment” utility as shown above to launch the same. As shown in the below screenshot, you can choose the target device from the utility screen. If you have your Windows Phone unlocked, you can deploy the XAP in that physical device too. To unlock your Windows Phone device, follow this post: How to Unlock Your WP7 Device for Development?

 

Windows Phone Application Deployment - Select the Device

 

Once you select the proper target from the above screen, click “Browse” to select the XAP file that you want to deploy either in your physical device or phone emulator. Now click “Deploy” button to start the deployment process.

 

Windows Phone Application Deployment - Browse for the XAP

 

Once it has been deploy successfully, you will see a success message in the screen as shown below and you can close this window:

 

Windows Phone Application Deployment - Deploy the XAP to the Device

 

Now you open your device or emulator to see the installed application in the application list. For our case, I deployed one of my Windows Phone application “ABC For kids” and you can see it as shown here:

 

Windows Phone Application Deployment - Find the deployed App in Device

 

If you don’t open your emulator before the deployment process, the utility will auto launch the emulator. Once booting process done, it will start the deployment process.

 

Issues Testing an Application from Emulator

You can deploy any app in emulator but all the features will not work in emulator. As you can’t setup email account, hence you will not be able to test email functionality. Same is applicable for social networking features and hence you can’t test them here too. There are many other features that you can’t test in your Windows Phone emulator. So, if you face such issues, don’t blame me or the developer.

 

Don’t forget to connect with me on Twitter and Facebook for technical updates and articles news. Also subscribe to my blog’s Newsletter to get all the updates delivered directly to your inbox. We won’t spam or share your email address as we respect your privacy.


If you have come this far, it means that you liked what you are reading. Why not reach little more and connect with me directly on Twitter, Facebook, Google+ and LinkedIn. I would love to hear your thoughts and opinions on my articles directly. Also, don't forget to share your views and/or feedback in the comment section below.

5 comments

  1. Good One. Thanks for such a beautiful response.

    ReplyDelete
  2. You have published a fantastic website. Very helpful for development activities. Keep it up with more new contents.

    ReplyDelete
  3. The article is quite helpful.I would like to know if any XAP related to business applications are available which can be downloaded for assessment purpose and how to open up a XAP File contents in WP7

    ReplyDelete
  4. This article was help full,i want some help that is i could deploy my xap file in emulator but once i opened my app it showed error as "We cant display this page right now".my app is phonegap related...plz help me

    ReplyDelete
  5. The article is quite helpful ,i want some help with this ...that is i could deploy the xap file in the emulator but once i opened the app i got error as "We cant display this page right now". my app is related to phonegap.

    ReplyDelete

 
© 2008-2016 Kunal-Chowdhury.com - Microsoft Technology Blog for developers and consumers | Designed by Kunal Chowdhury
Back to top