I read a very good article on how to call a
VB dll from C++ at
www.codeproject.com/com/vb_from_c.asp. But I'm having a few problems, so I thought I'd see if anybody out there knows where I'm going wrong, or if there's a better way to do it:
The steps I followed are as follows:
I have a
VB dll.
I want to call classes and methods in the
VB dll from C.
I registered the dll with regsvr32.
I used the OLE/COM object viewer to get the IDL for the dll.
I created a file oratrav.idl and pasted the text in.
I ran midl.exe as follows: midl c:\progra~1\micros~3\myprojects\oratraveller\oratr av.idl /h c:\progra~1\micros~3\myprojects\oratraveller\oratr av.h
But when I run MIDL, I get error MIDL2025, syntax error : expecting a type specification near "single".
Please can somebody explain to me where I'm going wrong?
(Also, please bear in mind that I am really an ANSI C programmer rather than MS Windows C++. Although I know what objects, instances and methods are, I'm easily lost when talking about Windows-platform-specific topics)
Thanks in advance
Andy