title: C++ MFC Debug Assertion Failed! in static MFC
body: <pre><code>Debug Assertion Failed!
  File: f:\dd\vctools\vc7libs\ship\atlmfc\src\mfc\objcore.cpp Line: 40
  </code></pre>
  
  <p>I'm having this issue when I'm trying to DoModal(or Create) MFC window using debug configuration - <code>Use MFC in a Static Library</code> and <code>Dynamic Library (.dll)</code>. On Release configuration everything is OK but I can't debug dll. MS VS 2010</p>