Compartilhar via


System Center

Executes a task.

Namespace: Microsoft.EnterpriseManagement
Assembly: Microsoft.EnterpriseManagement.Core (in microsoft.enterprisemanagement.core.dll)

Usage

'Usage
Dim instance As ITaskRuntimeManagement
Dim targets As IEnumerable(Of T)
Dim task As ManagementPackTask
Dim configuration As TaskConfiguration
Dim returnValue As IList(Of TaskResult)

returnValue = instance.ExecuteTask(targets, task, configuration)

Syntax

'Declaration
Function ExecuteTask(Of T As EnterpriseManagementObject) ( _
    targets As IEnumerable(Of T), _
    task As ManagementPackTask, _
    configuration As TaskConfiguration _
) As IList(Of TaskResult)
IList<TaskResult> ExecuteTask<T> (
    IEnumerable<T> targets,
    ManagementPackTask task,
    TaskConfiguration configuration
) where T : EnterpriseManagementObject
generic<typename T> where T : EnterpriseManagementObject
IList<TaskResult^>^ ExecuteTask (
    IEnumerable<T>^ targets, 
    ManagementPackTask^ task, 
    TaskConfiguration^ configuration
)

GenericParameters

  • T

Parameters

  • targets
    The entities to target.
  • task
    The task to submit.
  • configuration
    The configuration of the task.

Return Value

Returns IList.

The task results.

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 Vista, Windows Server 2003, and

Target Platforms

Windows Server 2008,Windows Server 2003

See Also

Reference

ITaskRuntimeManagement Interface
ITaskRuntimeManagement Members
Microsoft.EnterpriseManagement Namespace