I wonder how I can import an Interface Class in C++.NET which was written in VB.NET.
The Dll contains only a Interface class. If I write "Implement iInterface" in VB.NET, it'll load all Functions and Methods from the Interface.dll.
But how can I do this in C++.NET?
This is what the Interface.dll looks like:
Public Interface IPlugin
Function CreateInstance( _
ByRef pntMemory As MemoryArbiter, _
ByRef pntMessageQueue As clsMessageQueue, _
ByRef pntGPIO As clsGPIO, _
ByRef pntProgramSettings As Types, _
ByRef pntDisplayDriver As DisplayDriver _
) As Boolean
Function DeleteInstance() As Boolean
Sub Main_Loop()
Sub ForceUnload()
Sub Interrupt()
End Interface
This structure has to be imported to the c++ code.
In VB.NET it looks like this:
Imports System.ComponentModel.Composition
Imports System.Windows.Forms.Application
Imports Plugin_Interface
Imports SharedLibrary
Imports SharedLibrary.DisplayDriver
<Export(GetType(IPlugin))>
Public Class cPlugin
Implements IPlugin
'.... Class functions come here
I, however, just need a tanslation of the file above so I can import the C++ DLL via MEF in my VB.NET 2010 Application.
Hope someone knows how to handle this ... :)