ActivationRegistrationManager.RegisterForProtocolActivation Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Registers to activate the app when the specified URI scheme is executed via ShellExecute, Launcher.LaunchUriAsync, or the command-line.
public:
static void RegisterForProtocolActivation(Platform::String ^ scheme, Platform::String ^ logo, Platform::String ^ displayName, Platform::String ^ exePath);
/// [Windows.Foundation.Metadata.Experimental]
static void RegisterForProtocolActivation(winrt::hstring const& scheme, winrt::hstring const& logo, winrt::hstring const& displayName, winrt::hstring const& exePath);
static void RegisterForProtocolActivation(winrt::hstring const& scheme, winrt::hstring const& logo, winrt::hstring const& displayName, winrt::hstring const& exePath);
[Windows.Foundation.Metadata.Experimental]
public static void RegisterForProtocolActivation(string scheme, string logo, string displayName, string exePath);
public static void RegisterForProtocolActivation(string scheme, string logo, string displayName, string exePath);
function registerForProtocolActivation(scheme, logo, displayName, exePath)
Public Shared Sub RegisterForProtocolActivation (scheme As String, logo As String, displayName As String, exePath As String)
Parameters
- scheme
-
String
Platform::String
winrt::hstring
The URI scheme to register for activations, such as https
.
- logo
-
String
Platform::String
winrt::hstring
The path to the image or resource used by Windows for the URI scheme. For packaged apps, this parameter is a package-relative path to an image file. For unpackaged, this parameter is a literal filepath to a binary file (DLL, EXE) plus a resource index.
- displayName
-
String
Platform::String
winrt::hstring
This display name used by Windows for the URI scheme.
- exePath
-
String
Platform::String
winrt::hstring
The path to the executable to be activated. If you pass an empty string, the current exectuable will be activated by default. Typically this parameter is specified if the caller of this method is the app's installer rather than the app itself.
- Attributes
Applies to
See also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for