Task.HostObject Property

Definition

The build engine sets this property if the host IDE has associated a host object with this particular task.

C#
public Microsoft.Build.Framework.ITaskHost HostObject { get; set; }
C#
public Microsoft.Build.Framework.ITaskHost HostObject { [System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")] get; [System.Runtime.TargetedPatchingOptOut("Performance critical to inline this type of method across NGen image boundaries")] set; }

Property Value

The host object instance (can be null).

Implements

Attributes

Remarks

If the host IDE has associated a host object with this particular task, then the build engine sets this property.

The host object is provided by HostServices. Visual Studio determines the host object via a system registry key. For more information, see IVsMSBuildHostObject.

Applies to

Product Versions
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1