Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Creates a Visual Studio task that's executed with the specified context.
Namespace:  Microsoft.VisualStudio.Shell
Assembly:  Microsoft.VisualStudio.Shell.12.0 (in Microsoft.VisualStudio.Shell.12.0.dll)
Syntax
'Declaration
Public Shared Function CreateAndStartTask ( _
    scheduler As IVsTaskSchedulerService, _
    context As VsTaskRunContext, _
    pTaskBody As IVsTaskBody _
) As IVsTask
public static IVsTask CreateAndStartTask(
    IVsTaskSchedulerService scheduler,
    VsTaskRunContext context,
    IVsTaskBody pTaskBody
)
public:
static IVsTask^ CreateAndStartTask(
    IVsTaskSchedulerService^ scheduler, 
    VsTaskRunContext context, 
    IVsTaskBody^ pTaskBody
)
static member CreateAndStartTask : 
        scheduler:IVsTaskSchedulerService * 
        context:VsTaskRunContext * 
        pTaskBody:IVsTaskBody -> IVsTask
public static function CreateAndStartTask(
    scheduler : IVsTaskSchedulerService, 
    context : VsTaskRunContext, 
    pTaskBody : IVsTaskBody
) : IVsTask
Parameters
- scheduler 
 Type: Microsoft.VisualStudio.Shell.Interop.IVsTaskSchedulerService- [in] The task scheduler service. 
- context 
 Type: Microsoft.VisualStudio.Shell.VsTaskRunContext- [in] Where the task will be executed. 
- pTaskBody 
 Type: Microsoft.VisualStudio.Shell.Interop.IVsTaskBody- [in] The action to be executed. 
Return Value
Type: Microsoft.VisualStudio.Shell.Interop.IVsTask
The task that was created.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.