c++ inherits c#

  • Thread starter d g via .NET 247
  • Start date
D

d g via .NET 247

(Type your message here)

--------------------------------
From: d g

Hi

I was wondering if it was possible to inherit in c++ from c#

I have:

public interface IRxMarketFeedCallback
{

and

__gc class rox_callback : public IRxMarketFeedCallback
{

But the compiler complains it cannot instantiate the abstract base class. However all the functions are implemented:

//virtual ??
void onExit() {}

What am I doing wrong?

Cheers Dirk
 
C

Carl Daniel [VC++ MVP]

d said:
(Type your message here)

--------------------------------
From: d g

Hi

I was wondering if it was possible to inherit in c++ from c#

I have:

public interface IRxMarketFeedCallback
{

and

__gc class rox_callback : public IRxMarketFeedCallback
{

But the compiler complains it cannot instantiate the abstract base
class. However all the functions are implemented:

//virtual ??
void onExit() {}

What am I doing wrong?

If you really have the keyword virtual commented out, that's what you're
doing wrong. Otherwise, show a more complete example.

-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