Click here to Skip to main content
15,910,787 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Wierd GetFileSize problem Pin
Senkwe Chanda8-Jul-02 4:03
Senkwe Chanda8-Jul-02 4:03 
GeneralRe: Wierd GetFileSize problem Pin
Chris Losinger8-Jul-02 4:06
professionalChris Losinger8-Jul-02 4:06 
GeneralRe: Wierd GetFileSize problem Pin
Senkwe Chanda8-Jul-02 4:33
Senkwe Chanda8-Jul-02 4:33 
GeneralRe: Wierd GetFileSize problem Pin
Chris Losinger8-Jul-02 4:52
professionalChris Losinger8-Jul-02 4:52 
GeneralRe: Wierd GetFileSize problem Pin
Senkwe Chanda8-Jul-02 5:14
Senkwe Chanda8-Jul-02 5:14 
GeneralRe: Wierd GetFileSize problem Pin
Senkwe Chanda8-Jul-02 5:41
Senkwe Chanda8-Jul-02 5:41 
GeneralRe: Wierd GetFileSize problem Pin
Senkwe Chanda8-Jul-02 4:52
Senkwe Chanda8-Jul-02 4:52 
GeneralProblem with WM_CREATE Pin
S van Leent8-Jul-02 2:40
S van Leent8-Jul-02 2:40 
I am creating my own framework (some already know), but there is one problem handling the WM_CREATE message.

This is my code

EWindow::EWindow(EString caption, EControl *parent, UINT menu) : EControl()
{
this->hInstance = hInstance;
WNDCLASSEX wcex;

wcex.cbSize = sizeof(WNDCLASSEX);

wcex.style = CS_HREDRAW | CS_VREDRAW;
wcex.lpfnWndProc = (WNDPROC)OldControlProc;
wcex.cbClsExtra = 0;
wcex.cbWndExtra = 0;
wcex.hInstance = hInstance;
wcex.hIcon = NULL;
wcex.hCursor = LoadCursor(NULL, IDC_ARROW);
wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
wcex.lpszMenuName = (LPCTSTR)menu;
wcex.lpszClassName = caption.GetString();
wcex.hIconSm = NULL;

RegisterClassEx(&wcex);

EString wndclassstr = caption + "___";

hControl = CreateWindow(wndclassstr.GetString(), caption.GetString(), WS_OVERLAPPEDWINDOW,
CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, parent->GetHandle(), NULL, NULL, NULL);

SetWindowLong(hControl, GWL_USERDATA, reinterpret_cast<long>(this));
}

As you know, the WM_CREATE Message is sent within the CreateWindow function, but this isn't cought at the right place, because I want him to do it object oriented. So, after the SetWindowLong(...) function. Does anyone know how I can fool the system, so the WM_CREATE message is sent after the SetWindowLong(...)

thanks in advance,

Sjoerd van Leent


LPCSTR Dutch = "Double Dutch Smile | :) "
GeneralRe: Problem with WM_CREATE Pin
Mike Upton8-Jul-02 3:13
Mike Upton8-Jul-02 3:13 
GeneralRe: Problem with WM_CREATE Pin
S van Leent8-Jul-02 3:18
S van Leent8-Jul-02 3:18 
GeneralRe: Problem with WM_CREATE Pin
S van Leent8-Jul-02 4:23
S van Leent8-Jul-02 4:23 
GeneralConfiguring Database on a remote machine for DSN in my system Pin
8-Jul-02 2:06
suss8-Jul-02 2:06 
GeneralRe: Configuring Database on a remote machine for DSN in my system Pin
Prem Kumar8-Jul-02 3:08
Prem Kumar8-Jul-02 3:08 
GeneralRe: Configuring Database on a remote machine for DSN in my system Pin
sagmam8-Jul-02 5:45
sagmam8-Jul-02 5:45 
GeneralPlease help please urgent...... Pin
8-Jul-02 1:57
suss8-Jul-02 1:57 
GeneralRe: Attaching to the debugger Pin
Roger Allen8-Jul-02 2:59
Roger Allen8-Jul-02 2:59 
Generaladd-in question Pin
Hans Ruck8-Jul-02 1:49
Hans Ruck8-Jul-02 1:49 
Generalctrl+alt+del(windows 2000) Pin
slah8-Jul-02 1:43
slah8-Jul-02 1:43 
GeneralRe: ctrl+alt+del(windows 2000) Pin
DanielP8-Jul-02 5:42
DanielP8-Jul-02 5:42 
GeneralRe: ctrl+alt+del(windows 2000) Pin
-Dy9-Jul-02 1:54
-Dy9-Jul-02 1:54 
GeneralVisual .NET Debugger on 6.0 C++ compiler Pin
8-Jul-02 1:36
suss8-Jul-02 1:36 
QuestionOverride CArchive::IsStoring()==FALSE ? Pin
Koep8-Jul-02 1:05
Koep8-Jul-02 1:05 
GeneralSetWindowPos Problem Pin
AJ1238-Jul-02 0:39
AJ1238-Jul-02 0:39 
GeneralRe: SetWindowPos Problem Pin
Elrond8-Jul-02 4:53
Elrond8-Jul-02 4:53 
GeneralTask Bar in Full Screen Mode Implementation Pin
nilaysoft8-Jul-02 0:18
nilaysoft8-Jul-02 0:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.