Remoting Server c# --- client c++ ?

D

Desinderlase

I have created server side Remoting application in C#.
Remoting object interface in C# :

public interface IShareService
{
void setTestData(int data);
int getTestData();
}

Does anyone know how to create C++ client application that uses this
object?
Should I somehow include interface to cpp code or create new one?
I tried to create interface in cpp,

public __gc __interface IShareService
{
void setTestData(int data);
int getTestData();
};

but i got RemotingException : Cannot load type 'IShareInterface' ....

Any suggestions?
 
C

Carl Daniel [VC++ MVP]

Desinderlase said:
I have created server side Remoting application in C#.
Remoting object interface in C# :

public interface IShareService
{
void setTestData(int data);
int getTestData();
}

Does anyone know how to create C++ client application that uses this
object?
Should I somehow include interface to cpp code or create new one?
I tried to create interface in cpp,

public __gc __interface IShareService
{
void setTestData(int data);
int getTestData();
};

but i got RemotingException : Cannot load type 'IShareInterface' ....

Any suggestions?

Put the definition of the interface into a separate assembly that's
accessible to both the client and the server. It doesn't matter whether
than assembly is written in C# or C++ (managed, of course), or any other
..NET language. What does matter is that both ends of the connection are
using the same definition of the interface.

-cd
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top