This documentation is archived and is not being maintained.

ResolveComReference Class

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

Implements the ResolveComReference task. Use the ResolveComReference element in your project file to create and execute this task. For usage and parameter information, see ResolveComReference Task.

Namespace:  Microsoft.Build.Tasks
Assembly:  Microsoft.Build.Tasks.v4.0 (in Microsoft.Build.Tasks.v4.0.dll)

public sealed class ResolveComReference : AppDomainIsolatedTaskExtension

The ResolveComReference type exposes the following members.

Public methodResolveComReferenceInfrastructure. Initializes a new instance of the ResolveComReference class.

Public propertyBuildEngineGets or sets the build engine interface that is available to tasks. (Inherited from AppDomainIsolatedTask.)
Public propertyDelaySignInfrastructure. Gets or sets a Boolean value that specifies whether the ResolveComReference task places the public key in the assembly (true) or fully signs the assembly (false).
Public propertyEnvironmentVariablesGets or sets an array of name-value pairs of environment variables that should be passed to the spawned tlbimp.exe and aximp.exe in addition to (or selectively overriding) the regular environment block.
Public propertyExecuteAsToolProperty to allow multitargeting of ResolveComReferences: If true, tlbimp.exe and aximp.exe from the appropriate target framework will be run out-of-proc to generate the necessary wrapper assemblies.
Protected propertyHelpKeywordPrefixGets or sets the prefix that is used to compose Help keywords from string resource names. (Inherited from AppDomainIsolatedTask.)
Public propertyHostObjectGets or sets a host object instance that is associated with the derived Task. (Inherited from AppDomainIsolatedTask.)
Public propertyIncludeVersionInInteropNameWhen set to true, the typelib version will be included in the wrapper name. Default is false.
Public propertyKeyContainerInfrastructure. Gets or sets a container that holds a key pair.
Public propertyKeyFileInfrastructure. Gets or sets an item that contains a key pair.
Public propertyLogInfrastructure. Gets an instance of a TaskLoggingHelperExtension class containing task logging methods. (Inherited from AppDomainIsolatedTaskExtension.)
Public propertyNoClassMembersInfrastructure. Gets or sets a Boolean value that specifies whether to pass the TypeLibImporterFlags.PreventClassMembers flag to .tlb wrapper generation.
Public propertyResolvedAssemblyReferencesInfrastructure. Gets or sets the resolved assembly references.
Public propertyResolvedFilesInfrastructure. Gets or sets the fully qualified files on disk that correspond to the physical locations of the type libraries that were provided as input to this task.
Public propertyResolvedModulesInfrastructure. Gets or sets the paths to the modules that were found.
Public propertySdkToolsPathIf ExecuteAsTool is true, this must be set to the SDK tools path for the framework version being targeted.
Public propertyStateFileInfrastructure. Gets or sets the cache file for COM component timestamps.
Public propertyTargetFrameworkVersionThe project target framework version. Default is empty. which means there will be no filtering for the reference based on their target framework.
Public propertyTargetProcessorArchitectureGets or sets the name of the preferred target processor architecture, which is passed to the tlbimp.exe /machine flag after translation, for example x86, ia64, amd64 or msil.
Protected propertyTaskResourcesGets or sets culture-specific resources of the derived Task. (Inherited from AppDomainIsolatedTask.)
Public propertyTypeLibFilesInfrastructure. Gets or sets the type library file path to COM references.
Public propertyTypeLibNamesInfrastructure. Gets or sets the type library names to resolve.
Public propertyWrapperOutputDirectoryInfrastructure. Gets or sets the location on disk where the generated interop assembly is placed.

Public methodCreateObjRefCreates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from MarshalByRefObject.)
Public methodEquals(Object)Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Public methodExecuteInfrastructure. Executes the ResolveComReference task. (Overrides AppDomainIsolatedTask.Execute().)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetHashCodeServes as a hash function for a particular type. (Inherited from Object.)
Public methodGetLifetimeServiceRetrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from MarshalByRefObject.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodInitializeLifetimeServiceWhen overridden in a derived class, gives tasks infinite lease time. (Inherited from AppDomainIsolatedTask.)
Protected methodMemberwiseClone()Creates a shallow copy of the current Object. (Inherited from Object.)
Protected methodMemberwiseClone(Boolean)Creates a shallow copy of the current MarshalByRefObject object. (Inherited from MarshalByRefObject.)
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)

On a 64-bit machine, Framework64/<version>/msbuild cannot resolve COM objects registered as 32-bit components. For example, if you register a COM object with regsvr32 and then try to build a project targeting the x86 platform with Framework64/<version>/msbuild, the build is unable to resolve the COM object. If instead you build with Framework/<version>/msbuild, the build is able to resolve the COM object.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

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