JumpTask.Title JumpTask.Title JumpTask.Title JumpTask.Title Property


获取或设置针对跳转列表中的任务显示的文本。Gets or sets the text displayed for the task in the Jump List.

 property System::String ^ Title { System::String ^ get(); void set(System::String ^ value); };
public string Title { get; set; }
member this.Title : string with get, set
Public Property Title As String


针对跳转列表中的任务显示的文本。The text displayed for the task in the Jump List. 默认值为 nullThe default is null.


下面的示例演示如何JumpTask在标记中声明。The following example shows how to declare a JumpTask in markup. 在记事本应用程序中readme.txt 打开一个文本文件名称。JumpTaskThe JumpTask opens a text file name readme.txt in the Notepad application.

<JumpTask Title="Read Me" 
          Description="Open readme.txt in Notepad." 

下面的示例演示如何JumpTask在代码中配置。The following example shows how to configure a JumpTask in code. JumpTask打开计算器应用程序。The JumpTask opens the Calculator application.

// Configure a new JumpTask.
JumpTask jumpTask1 = new JumpTask();
// Get the path to Calculator and set the JumpTask properties.
jumpTask1.ApplicationPath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.SystemX86), "calc.exe");
jumpTask1.IconResourcePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.SystemX86), "calc.exe");
jumpTask1.Title = "Calculator";
jumpTask1.Description = "Open Calculator.";
jumpTask1.CustomCategory = "User Added Tasks";


通常, Title必须将属性设置JumpTask为, 以使作为可单击任务出现在 "跳转列表" 中。Typically, the Title property must be set for the JumpTask to appear in the Jump List as a clickable task.

或者, 您可以通过创建JumpTaskTitle指定和CustomCategory的来直观地分隔跳转列表中的项。Alternatively, you can visually separate items in a Jump List by creating a JumpTask that does not have a Title and CustomCategory specified. 此项JumpTask为空将在跳转列表中显示为水平线。This empty JumpTask will be displayed as a horizontal line in the Jump List. 在这种情况下, 可以设置其他属性, 但它们不会有任何影响。In this case, other properties can be set, but they will not have any effect.