You know even though I have been programming in C# for a bit I have never touched really on interop. I really would like to learn how to interface with C++. I know C++ basics and have programmed some windows with the C++/WINAPI even. I'm trying to start small with it and just return a string but the program crashes and doesn't let me see the error info. Here are my C++ files (dll win32 project file):
Question
sathenzar
You know even though I have been programming in C# for a bit I have never touched really on interop. I really would like to learn how to interface with C++. I know C++ basics and have programmed some windows with the C++/WINAPI even. I'm trying to start small with it and just return a string but the program crashes and doesn't let me see the error info. Here are my C++ files (dll win32 project file):
InteropTest.h
InteropTest.cpp
And finally my C# code (.net 4.5 console program):
Program.cs
The program fails on the dll call. It throws an accessviolationexception but hangs forever on that.
Link to comment
Share on other sites
6 answers to this question
Recommended Posts