
Richwin, Dr. Matthias wrote:
Hi all,
I try the following scenario:
- a C++ library (my own code), unmanaged, makes use of boost (e.g. regex) - a C++ .NET application (windows forms based) planned as GUI (having used Borland C++ builder in the past, the windows forms approach looks quite appealing to me)
- my C++ library header is included in the .Net form header file wrapped in a #pragma unmanaged/managed pair.
I compiles and links well.
For simple test purposes, I instantiate a class from my C++ library in the form constructor. Calling some unmanaged code from my library there creates a debug assertion:
"Debug Assertion Failed! [...] Expression: _CrtIsValidHeapPointer(pUserData)
This has nothing to do with Boost but rather with C++ mixed mode .Net programming. Why not ask in the appropriate Microsoft NG or online forum ?