   strange strange strange
  This crashes my app:calculated = TRUE;   MessageBox(NULL, "hallo", NULL, MB_OK);This doesnt:MessageBox(NULL, "hallo", NULL, MB_OK);calculated = TRUE;Really strange, it seems the app is unstable after calculated = TRUE. Any ideas what this could be? Perhaps a hardware problem? 
  Calculated = 1; ;  No thats not it. I dont think its the command itself, much rather my programm must have encountered some memory errors earlier that cause the crash now. But could it be I found nothing. Any typical problems you can think of. Its all in C/C++ class based, some inheritance. Based on MFC and uses DirectX8-CProgrammer ;  Try to see wich variable are declare before your calculated variable. If you have an array, check if you have an overflow.  The other hard way is to debug in asm to see what''s happen. Good Luck ;  strip the code down to the smallest example that still reproduces the problem and post it here ;  Well I''ve been checking for Memory leaks and such, checking wether I may have gone over an array bound i''ll definetley do soon. I''ll see if I can reduce the code into a postable way but I think not, cause its a rather big project.When the programm crashes I let it be debuged. Heres the Problem line maybe someone here can get some information out of this, cause my asm skills arent sufficient:mov    eax,dword ptr [eax+10h]-CProgrammer ;  There''s no such thing as "flukes" when you''re running a program. Don''t entertain the possibility.Based on previous posts you really need to switch to std::vector and use std::vector::at() to check every single array bounds acess, because its clear you''re clobbering your stack. 