JumpList.SetJumpList(Application, JumpList) JumpList.SetJumpList(Application, JumpList) JumpList.SetJumpList(Application, JumpList) Method

定義

セット、JumpListアプリケーションに関連付けられているオブジェクト。Sets the JumpList object associated with an application.

public:
 static void SetJumpList(System::Windows::Application ^ application, System::Windows::Shell::JumpList ^ value);
public static void SetJumpList (System.Windows.Application application, System.Windows.Shell.JumpList value);
static member SetJumpList : System.Windows.Application * System.Windows.Shell.JumpList -> unit

パラメーター

application
Application Application Application

関連付けられているアプリケーション、JumpListします。The application associated with the JumpList.

value
JumpList JumpList JumpList

JumpListアプリケーションに関連付けます。The JumpList to associate with the application.

次の例を作成する方法を示しています、JumpListコード。The following example shows how to create a JumpList in code. 静的なSetJumpListに関連付けるメソッドが呼び出される、JumpListと現在のアプリケーション。The static SetJumpList method is called to associate the JumpList with the current application. JumpList設定されている場合に、Windows シェルに自動的に適用します。The JumpList is automatically applied to the Windows shell when it is set. この例は例で使用できる、JumpListクラスの概要。This example is part of a larger example available in the JumpList class overview.

private void SetNewJumpList(object sender, RoutedEventArgs e)
{
    //Configure a new JumpTask
    JumpTask jumpTask1 = new JumpTask();
    // Get the path to WordPad and set the JumpTask properties.
    jumpTask1.ApplicationPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.System), "write.exe");
    jumpTask1.IconResourcePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.System), "write.exe");
    jumpTask1.Title = "WordPad";
    jumpTask1.Description = "Open WordPad.";
    jumpTask1.CustomCategory = "Jump List 2";
    // Create and set the new JumpList.
    JumpList jumpList2 = new JumpList();
    jumpList2.JumpItems.Add(jumpTask1);
    JumpList.SetJumpList(App.Current, jumpList2);
}

注釈

複数作成できますJumpListオブジェクト。You can create multiple JumpList objects. ただし、1 つだけJumpList一度に関連付けることができる、Applicationします。However, only one JumpList at a time can be associated with an Application. 呼び出す、SetJumpListを設定するメソッド、JumpListに関連付けられている、Applicationします。Call the SetJumpList method to set the JumpList currently associated with an Application.

適用対象