Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Modernizing Your Windows Applications with the Windows App SDK and WinUI

You're reading from   Modernizing Your Windows Applications with the Windows App SDK and WinUI Expand your desktop apps to support new features and deliver an integrated Windows 11 experience

Arrow left icon
Product type Paperback
Published in Apr 2022
Publisher Packt
ISBN-13 9781803235660
Length 514 pages
Edition 1st Edition
Languages
Arrow right icon
Authors (2):
Arrow left icon
Marc Plogas Marc Plogas
Author Profile Icon Marc Plogas
Marc Plogas
Matteo Pagani Matteo Pagani
Author Profile Icon Matteo Pagani
Matteo Pagani
Arrow right icon
View More author details
Toc

Table of Contents (19) Chapters Close

Preface 1. Section 1: Basic Concepts
2. Chapter 1: Getting Started with the Windows App SDK and WinUI FREE CHAPTER 3. Section 2: Modernization Journey
4. Chapter 2: The Windows App SDK for a Windows Forms Developer 5. Chapter 3: The Windows App SDK for a WPF Developer 6. Chapter 4: The Windows App SDK for a UWP Developer 7. Chapter 5: Designing Your Application 8. Chapter 6: Building a Future-Proof Architecture 9. Section 3: Integrating Your App with the Windows Ecosystem
10. Chapter 7: Migrating Your Windows Applications to the Windows App SDK and WinUI 11. Chapter 8: Integrating Your Application with the Windows Ecosystem 12. Chapter 9: Implementing Notifications 13. Chapter 10: Infusing Your Apps with Machine Learning Using WinML 14. Section 4: Distributing Your Application
15. Chapter 11: Publishing Your Application 16. Chapter 12: Enabling CI/CD for Your Windows Applications 17. Assessments 18. Other Books You May Enjoy

Supporting the application's activation

UWP offers a rich set of activation contracts, which enables the application to be launched by multiple actions—file type association, protocol association, sharing, and automatic startup are just a few examples.

To handle these scenarios, the App class in a UWP application provides multiple hooks that you can override, such as OnFileActivated (when the app is opened using a file type association), OnShareTargetActivated (when the app is opened using a share contract), or the more generic OnActivated, which can be used to handle all other scenarios for which there isn't a dedicated handler.

The UWP model offers dedicated hooks since, by default, applications are run in a single-instance mode. This means that if the application is running and it gets activated by another action (such as the user double-clicking on a file and then which type is associated with the app), the already activated instance will receive the information...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime