Net Framework Tool
Type library import program (TLBIMP.EXE)
The Type Library Import Program converts the type definition in the COM-type library to an equivalent definition in the public language runtime assembly. The output of TLbimp.exe is a binary (assembly) that contains running dollar data for the type of time defined in the original type library. This file can be checked using tools such as iLDasm.exe.
Copy to clipboard
TLBIMP TLBFILE [OPTIONS]
parameter
Parameter Description TLBFile contains any file of any file of the COM type library.
Option Description / AsMVersion: VersionNumber Specifies the version number of the assembly you want to generate. Specify VersionNumber in Major.minor.Build.Revision format. / DelaySign Specifies the use of delay signature to sign the result assembly with a strong name. This option must be specified with / keycontainer:, / keyfile: or / publickey: option. For more information on delaying the signature process, see the delay is the program collection. / Help shows the command syntax and options for the tool. / KeyContainer: ContainerName uses the public key / private key pair found in the key container specified in ContainerName, issues a set of results set with strong names. / keyfile: filename is using the issuer of the issuer found in FileName, issuing a result assembly with a strong name. / NameSpace: NameSpace Specifies the namespace where the assembly is generated. / NOCLASSMEMBERS prevents TLBIMP.EXE from adding members to the class. This avoids potential TypeLoadException. / NOLOGO Cancels the Microsoft Startup title. / OUT: FILENAME Specifies the namespace of the output file, the assembly, and the namespace to write to the metadata definition. If the interface definition language (IDL) custom property specified by the type library explicitly controls the namespace of the assembly, the / OUT option has no effect on the namespace of the assembly. If you do not specify this option, TLBIMP.exe writes metadata in a file with the same name as the actual type library defined within the input file, and assigns a .dll extension. If the name of the output file is the same as the name of the input file, the tool will generate an error to prevent rewriting the type library. / Primary Generates the primary interface of the specified type library. Related information will be added to the assembly to indicate that the issuer of the type library has generated the assembly. By specifying the primary Interop assembly, you can distinguish between a publisher's assembly from any other program set from this type library from that type library. If you are the issuer of the type library imported by TLBIMP.exe, you should only use the / primary option. Note that you must issue a master Interop assembly with strong names. For more information, see the main interoperability assembly. / publickey: filename Specifies a file that contains the public key to issue the result assembly. If you specify / keyfile: or / keycontainer: option instead of / publickey:, tlbimp.exe will generate a public key based on the / keyfile: or / keycontainer: the public key / private key pair provided. Publickey: Option supports the test key and delayed signature scheme. This file uses a format generated by sn.exe. For more information, see the -p option in Sn.exe in the Strong Name Tool (sn.exe). / Reference: FileName Specifies an assembly file to resolve references to the type defined outside the current type library. If you do not specify / Reference options, TLBIMP.exe will automatically import any external type libraries that are imported in a recursive way. If you specify the / reference option, the tool will try to resolve the external type in the referenced program before importing other types of libraries. / Silent cancels the success message. / stricTref If this tool does not parse all references within the assembly specified by the current assembly, / reference option or all references within the registered primary interoperable assembly (PIA), do not import type libraries. / Strictref: NOPIA is the same as / stricTref, but ignores PIA.
/ sysArray specifies that the tool imports COM style SafeArray as a managed System.Array class type type. / TLBREFERENCE: FileName Specifies the type library file for resolving the type library reference without referring to the registry. Note that this option does not load some earlier type library format. However, you can still implicit earlier type library formats through registry or current directory. / Transform: TransformName Press the specified conversion metadata of the TransformName parameter. Specifying the Dispret as the TransformName parameter, the [OUT, RETVAL] parameter of the method that only supports only the scheduling interface (scheduling interface) is converted to the return value. For more information on this option, see the example behind this topic. / UNSAFE generates an interface without performing the .NET Framework security check. The method disclosed in this way may result in safety risks. This option should not be used if you don't understand the risk of this class. / verbose specifies the detailed mode; show additional information about the imported type library. /? Display the command syntax and options for the tool. Note that the command line option of TLBIMP.exe is not case sensitive and can be provided in any order. Simply specify enough options to uniquely identify it. Therefore, / n is equivalent to / NOLOGO equivalent, / ou: Outfile.dll equivalent to /out:outfile.dll.