Share via


TaskItem.Enabled Property

Definition

Gets or sets a value indicating whether the object is enabled.

public:
 property bool Enabled { bool get(); void set(bool value); };
public bool Enabled { get; set; }
member this.Enabled : bool with get, set
Public Property Enabled As Boolean

Property Value

true if the object is enabled; otherwise, false.

Examples

The following example enumerates the task items and enables all tasks of type MethodTaskItem.

    foreach (TaskItem item in items)
    {
        if (item is MethodTaskItem)
            item.Enabled = true;
    }
    return items;
}

Applies to