On a brand new Vista machine, I'm getting the following error - instantly - whenever I try to start a project in debug mode:
Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
I don't buy the "other memory is corrupt" part of the message. I thought the error might be related to a project I'd just moved to the new machine, but even a brand new blank project exhibits the same behavior. And I don't get any message when I Start Without Debugging.
I've read online about a few fixes:
- There was a service pack to .NET 2.0 in 2007 that addresses the issues. I'm on 3.5 SP1, so I doubt that's the problem.
- Compile explicitly for x86, because the DLLs you reference are 32-bit and you'll have issues. I'm on a Core 2 Duo, but running Vista 32-bit, so that shouldn't be a problem, right? (Plus, in the test project, no DLLs.)
- Under debug, uncheck "Suppress JIT optimization on module load". Didn't do anything for me.
- Wipe the whole OS and reinstall VS2008. (This apparently worked for a kid.) I don't have time for that right now.
I can probably do what I need to do without Debugging, but I'd sure like to have it back. If anyone here can think of why this might be happening, please let me know. Thanks.