Solved

Program Crash When Program minimized

Posted on 2007-04-06
4
474 Views
Last Modified: 2013-12-14
I have a C++ MFC application.  I recently started having the following problem: if I leave it running in the background (minimized ) for 10 or 15 minutes, when I eventually come back to it (select it in the taskbar), my application's windows draw very strangely, and the program crashes. By "strange", I mean that the windows that should be positioned at the bottom of the screen draw at the top, but without borders, when I select menu items, a dialog displays with another window inside it (that isn't supposed to be there), etc.  I get assert error messages also.  

I must note that this problem does NOT happen if I leave my application running and keep it in focus (ie, I DON'T minimize it).

Any help would be greatly appreciated.

0
Comment
Question by:clintMon
  • 2
4 Comments
 
LVL 4

Accepted Solution

by:
bikvi_sibro earned 250 total points
ID: 18864414
The first thought that comes to mind is that it might be a refresh issue.  Try running the debugger through the refresh process and see what happens when it is trying to restore itself.
0
 

Author Comment

by:clintMon
ID: 18864602
When you say "refresh process", what specifically do you mean?  Window redrawing?  OnSetActive() routines?
0
 
LVL 8

Assisted Solution

by:mxjijo
mxjijo earned 250 total points
ID: 18865256

Apparently its is hard to say what causing it. You should try to narrow down the problem.
Pls tell us as many details as possible.

1) What does this application do  ?
2) What is the earliest point you got the prob ?
3) Are you doing any large memory handling ?
4) What does the ASSERT say ?
You should be attaching the debugger when the assert/crash happens and  
0
 
LVL 8

Expert Comment

by:mxjijo
ID: 18865281
oops.. hit submit by mistake ..

You should be attaching the debugger when the assert/crash happens and  check the stack trace.
5) As bikvi_sibro suggested, start the app from the debugger and see what happens.

good luck.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
C++ to C# code conversion issue 4 98
Access 2013: API code to put hidden database icon in taskbar? 8 69
gdb doesn't stop on breakpoint 2 48
Issues with C++ Class 19 80
Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

914 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now