Share via


ActivationRegistrationManager.RegisterForStartupActivation メソッド

定義

レジストリ キーまたは既知のスタートアップ フォルダー内のショートカットが原因で、ユーザーが Windows OS にログインしてアプリを起動したときに、アプリをアクティブ化するために登録します。

public:
 static void RegisterForStartupActivation(Platform::String ^ taskId, Platform::String ^ exePath);
/// [Windows.Foundation.Metadata.Experimental]
 static void RegisterForStartupActivation(winrt::hstring const& taskId, winrt::hstring const& exePath);
 static void RegisterForStartupActivation(winrt::hstring const& taskId, winrt::hstring const& exePath);
[Windows.Foundation.Metadata.Experimental]
public static void RegisterForStartupActivation(string taskId, string exePath);
public static void RegisterForStartupActivation(string taskId, string exePath);
function registerForStartupActivation(taskId, exePath)
Public Shared Sub RegisterForStartupActivation (taskId As String, exePath As String)

パラメーター

taskId
String

Platform::String

winrt::hstring

UnregisterForStartupActivation メソッドを使用して、後でスタートアップ のアクティブ化の登録を解除するために使用できるアプリ定義 ID。

exePath
String

Platform::String

winrt::hstring

アクティブ化する実行可能ファイルへのパス。 空の文字列を渡すと、現在の exectuable が既定でアクティブになります。 通常、このメソッドの呼び出し元がアプリ自体ではなくアプリのインストーラーである場合、このパラメーターが指定されます。

属性

適用対象

こちらもご覧ください