hi guys, I'e got two programs which do exactly the same thing...one is based on a normal window and the other is based on a dialog box, all the program does is it draws a grid in the window or on the dialog box, then when you click the left mouse button in the window's client area it displays the co-ordinates of the square in whivh you clicked...

This works fine for the window but the dialog box doesn't appear to recieve WM_LBUTTONDOWN and other mouse messages generated by clicking on the client area...I slao tried the WM_NC*
but they don't work either!

Is this the correct behviour for a dialog box?
btw. the dialog box doen't have any controls on it...only the drawn picture

The Martial
Posted on 2001-10-18 19:05:34 by MArtial_Code
Are you checking for the WM_LBUTTONDOWN in the dlgProc, or in the main WndProc?
Posted on 2001-10-18 20:46:56 by sluggy
Normally a DlgProc receives the WM_LBUTTONDOWN message. Make sure your dialog box isnt "disabled".
Posted on 2001-10-19 02:57:29 by japheth
Cheers I found where I was going wrong....trying to program at 1am!!
I was testing the wrong value aginst the messages!!!!
it's fine now!

The Martial
Posted on 2001-10-19 04:39:42 by MArtial_Code