I have zero experience in C++, but have a few years C# experience.
Are there an examples out there showing how I can create a method in a C++ program which is then called from a C# program using the DLL?
Cheers
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Using p/invoke, you can call C++ code from C#.
Read this: Calling Win32 DLLs in C# with P/Invoke
Another small yet good article : Using P/Invoke to Access Win32 APIs
—
EDIT:
This aritcle explains how to create a DLL library in C and then use it with C#