Once again getting my hands dirty with old C++ MFC code and I ran into strange problem.
It looks like this has been well-known issue since VS 6.0 over VS2005 up to newest 2010 version.
If you are trying to debug C++ MFC application on 64Bit OS using Visual Studio 2010 you will most likely get System.AccessViolationException in “Unknow Module”.
Did some research over MSDN and as it turns out only solution to this problem is to disable RPC debugging.
In Visual Studio go to Tools->Options->Debugging->Native and just uncheck “Enable RPC debugging”. This setting is always enabled by default.
I will defiantly find my own post search for this solution in near future .
Hope it helps you and please don’t use MFC any more .