S
shel
Hi All,
Probably a silly question to those who know, but i'm a noob with C#
I have a COM component written in VB6 I'm trying to interop to from C#
(using the IDE 'Add Reference' capability to register the component).
Some functions work ok, but I have one function that takes a class
from the component and passes it to another function in a different
class within the same component. So in my C# application, I have a
call that looks something like :
m_oBusinessUnit.Init (m_oWorkstation)
The problem I have is that when C# registers the COM object for C#
interop compatibility, it creates the original Workstation class as
WorkstationClass, and the declaration in the VB COM component is
expecting just plain old Workstation as a parameter. So when I declare
m_oWorkstation in the C# app as a WorkstationClass object, there's a
conversion error when calling the Init function of the m_oBusinessUnit
class.
Any help would be greatly appreciated.
Regards
-Shel
Probably a silly question to those who know, but i'm a noob with C#

I have a COM component written in VB6 I'm trying to interop to from C#
(using the IDE 'Add Reference' capability to register the component).
Some functions work ok, but I have one function that takes a class
from the component and passes it to another function in a different
class within the same component. So in my C# application, I have a
call that looks something like :
m_oBusinessUnit.Init (m_oWorkstation)
The problem I have is that when C# registers the COM object for C#
interop compatibility, it creates the original Workstation class as
WorkstationClass, and the declaration in the VB COM component is
expecting just plain old Workstation as a parameter. So when I declare
m_oWorkstation in the C# app as a WorkstationClass object, there's a
conversion error when calling the Init function of the m_oBusinessUnit
class.
Any help would be greatly appreciated.
Regards
-Shel