At Build 2016, we showed you how to use the Desktop App Converter to bring your existing desktop applications to the universal .appx packaging format as a first step to bringing your application to the Universal Windows Platform (UWP). Once on UWP, your apps are easier for users to manage and install, and you can integrate engaging UWP functionality and reach customers across the Windows 10 platform, including on IoT devices, Xbox One and HoloLens. We’d like to take this opportunity to further provide some context about the converter and other tooling involved (previously part of Project “Centennial”), and help you get started with the Desktop Bridge.
Since the release of the initial preview in early April, we’ve already seen hundreds of apps being converted and deployed for early testing. With the latest Windows 10 Insider Preview Build 14342, you can now run the Desktop App Converter on the Professional version of Windows, alongside the Enterprise edition that was previously enabled. Now is a great time to get started with converting your existing desktop applications to bring them to UWP!
What is the Desktop Bridge?
The Desktop Bridge brings a number of important improvements to the Windows platform for all developers. First, you can convert existing Windows desktop apps or games to .appx packages, so your users will be able to install them easily and experience seamless updates, be it through the Windows Store or any distribution channel of your choice.
Once converted to the UWP application model, the desktop app has access to new UWP APIs, including Live Tiles, push notifications and local/roaming app data, which previously were inaccessible to desktop apps. With this conversion process, your existing code continues to run with minimal changes and UWP deployment ensures that whatever state the app writes to the PC is isolated and easily cleaned up on uninstall – addressing a major pain point users have had with desktop apps in the past. Additionally, the app can now expose App Services, run Background Tasks, and have a XAML UI by adding a UWP app container process to the same app package.
With your existing code now running in the UWP application model, it’s straightforward to add additional functionality over time, gradually migrating existing Win32/.NET code to move functionality into the app container. Running your code in the app container benefits the security of your user’s machine, and at the end of the migration results in a UWP app that can run on PCs, Phones, IoT devices, Xbox One and HoloLens.
- Convert – Create an .appx deployment package for your desktop application
- Enhance – Call new UWP APIs from your desktop application
- Extend – Add new functionality, such as UWP App Services and Background Tasks
- Migrate – Move more code into the app container part of your package, such as a XAML UI frontend
- Expand – Finish the migration of all code to the app container and expand your reach to all Windows devices
To get started, you need the current Windows 10 Insider Preview Build 14342 (or higher), and the Windows 10 Anniversary SDK Preview Build 14332 (or higher). Please keep this installation separate from your production environment, as this build does not output valid app package for Store deployment. Next you’ll need the latest Desktop App Converter to complete your development environment. This tool converts your desktop app installer (such as MSI) to an .appx package that can be deployed to a Windows 10 Anniversary Edition desktop. If you’re trialing Visual Studio “15” Preview 2, you can also take a look at the packaging and debug support for projects that are using the Desktop Bridge. For more information, please read the Visual Studio blog post on Visual Studio “15” support with the Desktop Bridge.
If your desktop application does not have an installer (e.g. deployment just consists of file copy operations), or you want to explore the Desktop Bridge with a simple example first, you can check out our sample repo on GitHub. Using the Basic Desktop Bridge App sample as a template, you can replace the sample .exe with your binaries, adjust the respective entries in the manifest according to the documentation and you are done with the conversion. You don’t even need to install and run the Desktop App Converter for this type of project!
Test, Update, Enhance and Extend your converted app
Once you have successfully converted your desktop app (either with the Desktop App Converter or manually), you are ready to deploy, test and enhance your app. Now that your app is in the UWP app model and has an .appx package, the methods for doing this are the same as for any UWP app. Check out our Deploy and Debug documentation for detailed steps on side-loading and debugging. Note that your converted app may need some code changes in some cases. Be sure to read the Preparing Your Desktop App for Conversion to UWP topic on the Windows Dev Center.
You can now iterate on your code and start enhancing your app with exciting new UWP features that were previously not available to desktop apps. Add background tasks and app services. Add a UWP process to your package to host a UWP XAML UI frontend, and so much more. We will continue to update the Desktop Bridge sample repo on GitHub to demonstrate many of these great UWP features consumed by converted desktop applications, as we are getting closer to the final release of the Windows 10 Anniversary Update.
Over the coming months, we’ll be sharing more in-depth information about these approaches, what the end-to-end developer process looks like and how to add new functionality to your existing app.
Help us improve the bridge
The Desktop Bridge offers an exciting path to migrate your existing desktop apps to UWP. It enables you to gradually move across the bridge at your own pace while keeping your existing code investments running at all times along the way.
As you explore the tools on current preview builds, we’re very keen on hearing about your experiences and receiving your feedback. The best place to make feature suggestions is on the Windows Developer UserVoice site. For questions and bug reports, please head over to the Developing Universal Windows apps forums.
- Desktop conversion for UWP apps on Dev Center
- Build 2016 breakout session – Bringing Existing Desktop Applications to the Universal Windows Platform by John Sheehan, Peyman Zanjani
- Build 2016 pre-record session – Bringing Desktop Apps to the UWP Using Desktop App Converter by David Tepper, Avneet Singh
- Channel 9 Live interview – John Sheehan, David Tepper, Stefan Wick
Written by Stefan Wick, Principal Program Manager Lead for the Desktop Bridge
Updated May 17, 2016 11:30 am