I have a C# exe and some vc++ dll's . I am creating a callBackFunction in C# whichh takes structure as its Parameters. My c++ dll will fill this structure and return it back.But 95% of the time My Exe crashes. My dll is multi threaded and my C# has backgroundWorker in it. I have put try catch block to check if any exceptions are coming or not but no exception is being caught. Can any one suggest a better way to send data from my vc++ dll to c# exe
-
1You need to put in example code. There are a number of different ways of passing parameters and handling C++ callbacks, any of which can go horribly wrong if done incorrectly. Be aware also that in spite of what the documentation says, .NET has a habit of garbage collecting managed thunks out from under C++.plinth– plinth2010-02-18 14:20:29 +00:00Commented Feb 18, 2010 at 14:20
Add a comment
|