Solved

Assertion on CWnd::MoveWindow()

Posted on 1997-07-21
2
381 Views
Last Modified: 2013-11-20
Hi,

I get an assertion when I move a control window in a dialog box in response to the first WM_SIZE message the dialog receives. The assertion tells me that the control is not a valid window. It looks like the control is not fully created when I receive the message.

Can someone explain me what's going on. There is obviouly something I don't catch.

Thanks for your help.
0
Comment
Question by:Koensayr
2 Comments
 
LVL 4

Accepted Solution

by:
AVaulin earned 50 total points
Comment Utility
All right. All control window are not valid when dialog window receives WM_SIZE message first time. Do what you want in OnInitDialog method or at first WM_PAINT message receiving.
0
 

Author Comment

by:Koensayr
Comment Utility
Just to make sure I understand everything

What you're saying is that it is normal to receive a WM_SIZE message before OnInitDialog is called and there's nothing I can do about it? right.

Thanks
Eric


0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

728 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

15 Experts available now in Live!

Get 1:1 Help Now