Problems with WM_QUERYENDSESSION

Problems with WM_QUERYENDSESSION

Post by unai » Thu, 04 Oct 2001 19:20:05



Hi all!.
I have a problem with a program.... the question is that i need to
intercept the WM_QUERYENDSESSION message in order to make a little
actions before reset the pc. But this message never arrives to my
event loop.
I have a loop like this in my program:

LRESULT CALLBACK WndProc(HWND hWnd, UINT message,WPARAM wParam, LPARAM
lParam)
{
...
...
        switch(message)
        {
        case "ANOTHER_CASES THAT WORKS RIGHT"
        ....
        break;
        case WM_QUERYENDSESSION:
        ... My actions
        break;
        }

Quote:}

does anybody know why this messages never arrives to my loop? I'm
really in a hurry and i can't discover the problem. :-(
Thanks for all.