Back to Devexpress

JumpListItemTask.Click Event

windowsforms-devexpress-dot-utils-dot-taskbar-dot-jumplistitemtask-b2f2d586.md

latest2.2 KB
Original Source

JumpListItemTask.Click Event

Fires when a task has been clicked.

Namespace : DevExpress.Utils.Taskbar

Assembly : DevExpress.Utils.v25.2.dll

NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core

Declaration

csharp
[DXCategory("Events")]
public event EventHandler Click
vb
<DXCategory("Events")>
Public Event Click As EventHandler

Event Data

The Click event's data class is EventArgs.

Remarks

A click on a task in the Jump List does the following:

  • Launches a file or folder specified by the JumpListItemTask.Path property (if this property is not empty).
  • Fires the Click event.

Important

Note that the jump list tasks require the application to be currently running in order to handle their Click events. After the application was closed, only tasks with their JumpListItemTask.Path properties specified remain functional.

In the following example, the Click event is handled to close the current form on task clicking:

csharp
private void jumpListItemTask1_Click(object sender, EventArgs e) {
    this.BeginInvoke(new MethodInvoker(delegate {
        this.Close();
   }));
}
vb
Private Sub JumpListItemTask1_Click(sender As Object, e As EventArgs) Handles JumpListItemTask1.Click
    Me.BeginInvoke(New MethodInvoker(Sub() Me.Close()))
End Sub

See Also

Path

JumpListItemTask Class

JumpListItemTask Members

DevExpress.Utils.Taskbar Namespace