Development Sideloading of Windows Store Apps

 Mar 12, 2015

If you want to run a Windows Store App on your tablet or laptop, the normal procedure is to visit the Windows Store, find the app you want and then install it on your device. After that, you can launch the app by clicking or tapping on its tile on the Start screen. You can't download or install the app from any alternative site or even manually copy some executable to your local hard drive and double-click the exe to launch the app. It's quite different from desktop apps. But what if you are the developer of a new app and you want to test your app in a remote device?

In today's blog post I will show you the steps to install an app in a device for testing purposes without first publishing the app in the Windows Store. This technique is called Development Sideloading.

It is very advisable to go through this process before the final publishing step because running the app in a device other than the machine you used to develop the app can uncover issues that would not show up otherwise. Even the simulator cannot uncover issues that only a real device would reveal to you.

So let's go through the steps to create an app Package using Visual Studio 2013.

  1. Open the Project menu and point to Store. In the submenu that opens up click the “Create App Packages…” menu item. This will start the Create App Package wizard. In the first screen, you have to say if you want to build a package to upload to the Windows Store. Select No and click Next.
  2. If you have not yet signed up for a Windows Store Developer account, a windows opens up for you to enter your Microsoft account credentials, and enter an email or mobile number to receive a code. In a few seconds, the code will be sent to you and you can fill in the code box and click Next.
  3. The page Select and Configure Packages is displayed. In the Output location box, enter a location for the folder where all the generated distribution files will be stored. Check the check boxes for the architectures your app supports: x86, x64, ARM, or Neutral. For each one, you can use a Debug or a Release configuration. For a more realistic testing, the Release option is the best choice. Click Create.
  4. Now go to the output location folder you specified in the first screen. You will find .appx files for each of the platforms your app supports. The .appx file is essentially a .zip file containing all the deliverables that will be deployed to the testing device when the app is installed. You can change the extension to zip if you want to see all those files, but remember to change it back to .appx.
  5. In the location folder, you will also find a file with extension .cer. This is a certificate that will be used to sign the app in the testing device. Another important file is a PowerShell script, a file with extension .ps1, that will be used to install the app. This script will play the same role as going to Windows Store and selecting an app to install in your device.
  6. Now copy the location folder into the testing device by any means. Then right-click the .ps1 script and select Run with PowerShell. The first action will be the installation of the certificate. You will be prompted to start an elevated process and then to allow the certificate to be installed. The final step in the script is the installation of the app. Once the script completes, your app will be ready to use. Open the Start screen and click its tile to launch the app.
  7. To learn more about Windows Store Apps, I would recommend the Visual Studio Training courses 20484: Essentials of Developing Windows Store Apps Using C# and 20485: Advanced Windows Store App Development Using C#.
  8. How do your Excel skills stack up?   

    Test Now  

About the Author:

Newton Godoy  

With over 17 years of in-class training experience and over 16 years of industry experience, Newton offers students a wealth of real-world technical knowledge and expertise in the areas of .NET application development, SQL Server and SharePoint Server. After spending several years lecturing as a professor, Newton found his true calling and began his career as a MCT. He worked as a technical trainer for some of Brazil’s and Australia’s largest corporate training organisations before finally finding a home with New Horizons where he is now one of our top trainers. Newton brings a thorough mentoring capability to the classroom where he can advise on technical issues and challenges often beyond the scope of the course curriculum. His combination of technical knowledge and instructor experience make him one of the most respected instructors within the IT training industry.

Read full bio
top