Click here to Skip to main content
15,893,381 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Questionsimple name change of tree control does not work ?? Pin
Member 25844747-Jul-13 18:36
Member 25844747-Jul-13 18:36 
AnswerRe: simple name change of tree control does not work ?? Pin
Jonathan Davies7-Jul-13 22:44
Jonathan Davies7-Jul-13 22:44 
AnswerRe: simple name change of tree control does not work ?? Pin
Richard MacCutchan8-Jul-13 5:45
mveRichard MacCutchan8-Jul-13 5:45 
GeneralRe: simple name change of tree control does not work ?? Pin
Member 25844749-Jul-13 8:06
Member 25844749-Jul-13 8:06 
Questionwant to make circular progress bar on the dialog?? Give some tips! Pin
Sun-Mi Kang7-Jul-13 16:45
Sun-Mi Kang7-Jul-13 16:45 
AnswerRe: want to make circular progress bar on the dialog?? Give some tips! Pin
«_Superman_»7-Jul-13 19:12
professional«_Superman_»7-Jul-13 19:12 
GeneralRe: Thank (^__^).. I can try~! Pin
Sun-Mi Kang7-Jul-13 19:20
Sun-Mi Kang7-Jul-13 19:20 
AnswerRe: want to make circular progress bar on the dialog?? Give some tips! Pin
Richard MacCutchan7-Jul-13 20:42
mveRichard MacCutchan7-Jul-13 20:42 
AnswerRe: want to make circular progress bar on the dialog?? Give some tips! Pin
Soumyajit Satpathy10-Jul-13 4:57
Soumyajit Satpathy10-Jul-13 4:57 
QuestionTab control with custom draw? Pin
JoneLe866-Jul-13 7:35
JoneLe866-Jul-13 7:35 
Questionhow to set entire console window background color with given RGB(SetConsoleScreenBufferInfoEx)? Pin
Falconapollo6-Jul-13 2:33
Falconapollo6-Jul-13 2:33 
AnswerRe: how to set entire console window background color with given RGB(SetConsoleScreenBufferInfoEx)? Pin
Richard MacCutchan6-Jul-13 4:46
mveRichard MacCutchan6-Jul-13 4:46 
GeneralRe: how to set entire console window background color with given RGB(SetConsoleScreenBufferInfoEx)? Pin
Falconapollo6-Jul-13 6:35
Falconapollo6-Jul-13 6:35 
GeneralRe: how to set entire console window background color with given RGB(SetConsoleScreenBufferInfoEx)? Pin
Richard MacCutchan6-Jul-13 7:12
mveRichard MacCutchan6-Jul-13 7:12 
QuestionModeless Dialog with Message Loop Pin
Manish K. Agarwal4-Jul-13 21:32
Manish K. Agarwal4-Jul-13 21:32 
AnswerRe: Modeless Dialog with Message Loop Pin
pasztorpisti5-Jul-13 14:50
pasztorpisti5-Jul-13 14:50 
GeneralRe: Modeless Dialog with Message Loop Pin
Manish K. Agarwal5-Jul-13 18:42
Manish K. Agarwal5-Jul-13 18:42 
GeneralRe: Modeless Dialog with Message Loop Pin
pasztorpisti6-Jul-13 1:55
pasztorpisti6-Jul-13 1:55 
GeneralRe: Modeless Dialog with Message Loop Pin
pasztorpisti6-Jul-13 2:08
pasztorpisti6-Jul-13 2:08 
GeneralRe: Modeless Dialog with Message Loop Pin
Manish K. Agarwal7-Jul-13 21:17
Manish K. Agarwal7-Jul-13 21:17 
GeneralRe: Modeless Dialog with Message Loop Pin
pasztorpisti7-Jul-13 22:11
pasztorpisti7-Jul-13 22:11 
Thank you for posting, WM_CLOSE should be okay. You don't check the return value of PeekMessage (that should always be zero but its better to make sure...) and you should check Msg.hwnd whether its the main window hwnd or something else (it could be one of your dialog hwnds or any other HWND inside the IE process). I would write "if (PeekMessage()) { check for WM_CLOSE }". You can get the main window hwnd by performing the following operation on one of your activex hwnds that are placed directly/indirectly on your main window:
C++
HWND GetRootWindow(HWND hwnd)
{
    for (;;)
    {
        HWND parent = GetParent(hwnd);
        if (!parent)
            return hwnd;
        hwnd = parent;
    }
}

WM_SYSCOMMAND/SC_CLOSE is gui specific (it indicates that someone pressed X on the window), noone should put critical handling on this message as your window can easily get simulated WM_CLOSE messages without gui interaction/WM_SYSCOMMAND/SC_CLOSE.
GeneralRe: Modeless Dialog with Message Loop Pin
Manish K. Agarwal7-Jul-13 22:53
Manish K. Agarwal7-Jul-13 22:53 
GeneralRe: Modeless Dialog with Message Loop Pin
pasztorpisti8-Jul-13 2:24
pasztorpisti8-Jul-13 2:24 
AnswerRe: Modeless Dialog with Message Loop Pin
Erudite_Eric7-Jul-13 23:26
Erudite_Eric7-Jul-13 23:26 
GeneralRe: Modeless Dialog with Message Loop Pin
pasztorpisti8-Jul-13 8:40
pasztorpisti8-Jul-13 8:40 

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.