Share via


TaskCondition Generic Class

Used to associate a task to a business object that has been selected in the list pane of the Administration Console.

Namespace: Microsoft.EssentialBusinessServer.Console.ObjectModel
Assembly: Microsoft.EssentialBusinessServer.Console.ObjectModel (in microsoft.essentialbusinessserver.console.objectmodel.dll)

Usage

Syntax

'Declaration
Public NotInheritable Class TaskCondition(Of TBusinessObject)
public static class TaskCondition<TBusinessObject>
generic<typename TBusinessObject>
public ref class TaskCondition abstract sealed

Example

The following code example shows how to define a SelectionTask and define a TaskCondition object for the task using a delegate method:

SelectionTask<BusinessObject> task = null;
task = new ProcessTask<BusinessObject>("Selection Task", "notepad.exe");
task.ConditionProvider = ShouldShowTask;

private static TaskCondition ShouldShowTask(BusinessObject businessObj)
{
    return businessObj.OSVersion == "Windows Vista" ?
         TaskCondition.Default : TaskCondition.NotApplicable;
}

Remarks

TBusinessObject represents a business object that encapsulates information and methods that relate to business data or business functionality. The information in a business object is exposed as properties.

Inheritance Hierarchy

System.Object
  Microsoft.EssentialBusinessServer.Console.ObjectModel.TaskCondition

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Platforms

Development Platforms

Windows Server 2008 64-bit Edition, Windows Vista 64-bit Edition, Windows Essential Business Server 2008 Standard, Windows Essential Business Server 2008 Premium

Target Platforms

Windows Essential Business Server 2008 Standard, Windows Essential Business Server 2008 Premium

See Also

Reference

TaskCondition Members
Microsoft.EssentialBusinessServer.Console.ObjectModel Namespace