Click here to Skip to main content
15,905,686 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: how to get the line number of exception (details) in a try catch(...) block Pin
Matthew Faithfull17-Oct-07 0:15
Matthew Faithfull17-Oct-07 0:15 
GeneralRe: how to get the line number of exception (details) in a try catch(...) block Pin
Rocky#17-Oct-07 0:22
Rocky#17-Oct-07 0:22 
AnswerRe: how to get the line number of exception (details) in a try catch(...) block Pin
Mark Salsbery17-Oct-07 5:39
Mark Salsbery17-Oct-07 5:39 
GeneralRe: how to get the line number of exception (details) in a try catch(...) block Pin
Rocky#21-Oct-07 19:29
Rocky#21-Oct-07 19:29 
GeneralRe: how to get the line number of exception (details) in a try catch(...) block Pin
Mark Salsbery23-Oct-07 8:03
Mark Salsbery23-Oct-07 8:03 
QuestionSmall doubt Pin
kuttiam16-Oct-07 21:30
kuttiam16-Oct-07 21:30 
AnswerRe: Small doubt Pin
chandu00416-Oct-07 21:59
chandu00416-Oct-07 21:59 
AnswerRe: Small doubt Pin
Nelek16-Oct-07 22:04
protectorNelek16-Oct-07 22:04 
As the MessageBox comes from CWnd and CDialog is a CWnd derived class but "independant" you can try

CDialog* pDlg = (CDialog*) GetActiveWindow ();
if (pDlg->IsKindOf(RUNTIME_CLASS(CDialog)))
//you have a dialog
else
//you have another thing, maybe a messagebox, maybe a view, maybe a window


Another way to do the difference is the first member of both possibilites. By MessageBox the first member is a handler o a window hWnd, and in a DialogBox this handler is of the application instance hInstance

Hope it helps

Greetings.

--------
M.D.V.

If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?

Help me to understand what I'm saying, and I'll explain it better to you

Wink | ;)

GeneralRe: Small doubt Pin
kuttiam17-Oct-07 19:07
kuttiam17-Oct-07 19:07 
AnswerRe: Small doubt Pin
ThatsAlok17-Oct-07 1:37
ThatsAlok17-Oct-07 1:37 
Questionwstring to string question Pin
monsieur_jj16-Oct-07 21:22
monsieur_jj16-Oct-07 21:22 
AnswerRe: wstring to string question [modified] Pin
ThatsAlok17-Oct-07 1:36
ThatsAlok17-Oct-07 1:36 
QuestionHow to display only console window and hiding dialogbox? Pin
mss8116-Oct-07 21:17
mss8116-Oct-07 21:17 
AnswerRe: How to display only console window and hiding dialogbox? Pin
Nelek16-Oct-07 21:55
protectorNelek16-Oct-07 21:55 
AnswerRe: How to display only console window and hiding dialogbox? Pin
mss8116-Oct-07 22:05
mss8116-Oct-07 22:05 
GeneralRe: How to display only console window and hiding dialogbox? Pin
Nelek17-Oct-07 0:05
protectorNelek17-Oct-07 0:05 
GeneralRe: How to display only console window and hiding dialogbox? Pin
ThatsAlok17-Oct-07 20:36
ThatsAlok17-Oct-07 20:36 
GeneralRe: How to display only console window and hiding dialogbox? Pin
ThatsAlok17-Oct-07 20:36
ThatsAlok17-Oct-07 20:36 
AnswerRe: How to display only console window and hiding dialogbox? Pin
Mark Salsbery17-Oct-07 5:51
Mark Salsbery17-Oct-07 5:51 
GeneralRe: How to display only console window and hiding dialogbox? Pin
ThatsAlok17-Oct-07 20:37
ThatsAlok17-Oct-07 20:37 
Questionstring convertion Pin
Jhony george16-Oct-07 20:55
Jhony george16-Oct-07 20:55 
AnswerRe: string convertion Pin
Hamid_RT16-Oct-07 21:08
Hamid_RT16-Oct-07 21:08 
AnswerRe: string convertion Pin
jhwurmbach16-Oct-07 21:08
jhwurmbach16-Oct-07 21:08 
QuestionRe: string convertion Pin
David Crow17-Oct-07 3:09
David Crow17-Oct-07 3:09 
GeneralRe: string convertion Pin
Jhony george16-Oct-07 21:13
Jhony george16-Oct-07 21:13 

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.