I have a .exe file I've been given which has COM classes inside it -- these are from C++, not .net ComVisible
types
I'd like to use those classes inside my .net project, but I can't add a reference to the exe; when I try I get
DIALOG BOX:
---------------------------
Microsoft Visual Studio
---------------------------
A reference to 'C:\Program Files\blah\blah.exe'
could not be added. Please make sure that the
file is accessible, and that it is a valid
assembly or COM component.
---------------------------
OK
---------------------------
tlbimp also fails;
TLBIMP OUTPUT:
> tlbimp blah.exe
Microsoft (R) .NET Framework Type Library
to Assembly Converter 3.5.30729.1
Copyright (C) Microsoft Corporation. All rights reserved.
TlbIml : error TI0000 : The input file
'c:\program files\blah\blah.exe' is not
a valid type library
But it really looks as if there are COM classes available; in my HKEY_CLASSES_ROOT
hive I can see entries for the different COM clasess;
REGISTRY ENTRY:
\HKEY_CLASSES_ROOT
\CLSID
\{456B14EA-4CCC-11D4-BB91-0020AFC894E9}
@="COM.Classname"
\InprocHandler32
@="ole32.dll"
\LocalServer32
"LocalServer32"=hex(7) ...
@="C:\\PROGRA~2\\blah\blah.exe"
\ProgID
@="COM.Classname"
Anyone got a clue about how, and even if, I can use these COM classes from within a .net project?