Ok, I am totally aware this is probably a lame question. The fact is that I have been working on this for so long that I can find an answer anymore. I´m getting (even more) retarded.
My question is simple:
Why can´t an Edit Control created at WM_CREATE using CreateWindowEx and a Edit Control created at a resource file have the exact same appearance? The one created in the resource file has that "3D style" no matter how much I play with it´s styles, I can´t get rid of it and make it "Flat" like the one created at WM_CREATE.
The same thing happens with ListBoxes, and Static controls.
Here´s an example using a listbox:
If you add this example above to a sample program you´ll see what I am talking about. Besides the normal difference in metrics, there´s that 3D border around the control created into the resource file. I need to get rid of that.Code://This is in my WNDPROC at WM_CREATE: textdebug = CreateWindowEx (0, TEXT ("listbox"), TEXT("test"), WS_CHILD | WS_VISIBLE | WS_BORDER | WS_VSCROLL | LBS_NOINTEGRALHEIGHT | LBS_NOSEL | LBS_DISABLENOSCROLL, 15, 252, 333, 104, mainWindow, (HMENU) 1201, hInstance, NULL) ; //This is in dialogs.rc ID_STATUSDLG DIALOG DISCARDABLE 1, 12, 237, 223 //EXSTYLE I have tried all possible styles here STYLE WS_CHILD /*I have tried all possible styles here*/ FONT 1, "MS Sans Serif" BEGIN LISTBOX "test", IDC_TEXTDEBUG, 5, 141, 223, 64, WS_CHILD | WS_VISIBLE | WS_BORDER | WS_VSCROLL | LBS_NOINTEGRALHEIGHT | LBS_NOSEL | LBS_DISABLENOSCROLL END
Any help will be great, thanks