How to register a legacy typelib (.tlb) on Windows 7

regtlibtypelibwindows 7

I have a new PC running Windows 7 and Visual Studio 2010, and need to register a legacy typelib (.tlb) to interface with an existing legacy application. However, regtlib.exe does not seem to be part of Windows 7 (I don't think it was part of Vista either), and regtlibv12.exe, available as part of Visual Studio 2005, seems to have disappeared with Visual Studio 2008 (and certainly Visual Studio 2010).

Microsoft forums and knowledge base articles refer to RegAsm.exe. I've tried RegAsm.exe, but that will only create and register a typelib from an existing dll or assembly (which I do not have). I can't believe there is no way to register an existing typelib on Windows 7. Any help would be most appreciated.

Best Answer

Well, I guess I can answer my own question (and for anyone else who has the same problem):

Apparently, regtlibv12.exe is part of Visual Studio 2010 (contrary to what I read on various Microsoft forums), but it is located in the Windows\Microsoft.NET\Framework\v4.0.30139 folder (not the v2.0.50727 folder). Using that executable I was able to successfully register the legacy typelib (.tlb).