I like to use an unmanaged C++ DLL in my program.
As I've less knownledge about C++ is not my prefered solution to write an own wrapper in C++.
However I found the entries in the C++ DLL and so I'm able for DLLImport in my C# application.
But the result is ever an exeption.
Now somebody told me, that the matter is that the library need to be used in it's own class.
In the snippet you can see how the class is done there and a short source that explain how to use it.
Is it possible to use it with C# without an wrapper writen in C++?
// Library Class
class RSCT_TERMINALCONNECT_API Rsct_TerminalConnect
// Konstruktion / Destruktion
int Connect(int _port);
int UpdateConnect(int _port, const char* _model);
int Disconnect(int _port);
BOOL CheckDownloadmode(Reader* _pReader);
extern RSCT_TERMINALCONNECT_API int nRsct_TerminalConnect;
// CPP access it like
Rsct_TerminalConnect* pTC = new Rsct_TerminalConnect();
ret = pTC->Connect(GetPort());