Windows.ApplicationModel.Activation.SearchActivatedEventArgs
March 3, 2023 ยท View on GitHub
-description
Provides information about the activated event that fires when the user searches the app from the Search charm and the app isn't the main app on screen.
JavaScript This type appears as webUISearchActivatedEventArgs.
-remarks
Important
To implement search in an app for Windows 10 or later, use AutoSuggestBox. See Auto-suggest box for more info.
You should not use Windows.ApplicationModel.Search APIs (SearchPane, SearchContract) or SearchBox APIs in apps for Windows 10 or later.
If your app integrates with the Search contract, a SearchActivatedEventArgs object is passed to your app's OnSearchActivated activation point handler when the user searches the app from the Search charm and your app is not the main app on screen. This type of activation is indicated by the ActivationKind.Search value returned by the Kind property.
All Application overrides involved in an activation scenario should call Window.Activate in their implementations.
Version history
| Windows version | SDK version | Value added |
|---|---|---|
| 1607 | 14393 | User |
-examples
-see-also
Call asynchronous APIs in C# or Visual Basic, Application, Search contract sample (Windows 8), ActivationKind enumeration, Windows.ApplicationModel.Search namespace, Windows.ApplicationModel.Search.SearchPane class, Windows.UI.WebUI.WebUIApplication.Activated event, OnSearchActivated, Windows.UI.Core.CoreApplicationView.Activated event