Is it possible to call a c++ function from c-sharp.

  • Thread starter Thread starter chip
  • Start date Start date
C

chip

I know it can be done in a dll, but is it possible to call a c++ / c
function directly from c-sharp.

-chip
 
No, You have to use the PInvoke services in order to call exported C style
functions from C#.
please check the PInvoke services in MSDN.

Willy.
 
Willy Denoyette said:
No, You have to use the PInvoke services in order to call exported C style
functions from C#.
please check the PInvoke services in MSDN.

Thank you,

So, that means that it is not possible to add a c++ source
to a c# project directly and link them together,
I have to make it in a dll ?

-chip
 
chip said:
Thank you,

So, that means that it is not possible to add a c++ source
to a c# project directly and link them together,
I have to make it in a dll ?

Right.

Willy.
 
Back
Top