NAnt SDK Documentation - v0.85-nightly-2005-11-09

TlbImpTask Class

[This is preliminary documentation and subject to change.]

Imports a type library to a .NET assembly (wraps Microsoft's tlbimp.exe).

For a list of all members of this type, see TlbImpTask Members.

System.Object
   NAnt.Core.Element
      NAnt.Core.Task
         NAnt.Core.Tasks.ExternalProgramBase
            NAnt.Win32.Tasks.TlbImpTask

[Visual Basic]
<ProgramLocation(LocationType:=LocationType.FrameworkSdkDir), _  TaskName(Name:="tlbimp")>
Public Class TlbImpTask
    Inherits ExternalProgramBase
[C#]
[ProgramLocation(LocationType=LocationType.FrameworkSdkDir)]
[TaskName(Name="tlbimp")]
public class TlbImpTask : ExternalProgramBase

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Remarks

This task lets you easily create interop assemblies. By default, it will not reimport if the underlying COM TypeLib or reference has not changed.

See the Microsoft.NET Framework SDK documentation for details.

Example

Import LegacyCOM.dll to DotNetAssembly.dll.

                
            <tlbimp typelib="LegacyCOM.dll" output="DotNetAssembly.dll" />
                
              

Requirements

Namespace: NAnt.Win32.Tasks

Assembly: NAnt.Win32Tasks (in NAnt.Win32Tasks.dll)

See Also

TlbImpTask Members | NAnt.Win32.Tasks Namespace