Click here to Skip to main content
15,907,677 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Instead of using nested if-else Pin
Hamid_RT1-Dec-08 4:34
Hamid_RT1-Dec-08 4:34 
GeneralRe: Instead of using nested if-else Pin
Code-o-mat1-Dec-08 5:30
Code-o-mat1-Dec-08 5:30 
GeneralRe: Instead of using nested if-else Pin
ssclaire1-Dec-08 7:55
ssclaire1-Dec-08 7:55 
GeneralRe: Instead of using nested if-else Pin
CPallini1-Dec-08 8:09
mveCPallini1-Dec-08 8:09 
GeneralRe: Instead of using nested if-else Pin
Nemanja Trifunovic1-Dec-08 9:18
Nemanja Trifunovic1-Dec-08 9:18 
GeneralRe: Instead of using nested if-else Pin
Timothy Baldwin2-Dec-08 12:47
Timothy Baldwin2-Dec-08 12:47 
AnswerRe: Instead of using nested if-else Pin
CPallini1-Dec-08 5:47
mveCPallini1-Dec-08 5:47 
AnswerRe: Instead of using nested if-else Pin
David Crow1-Dec-08 10:17
David Crow1-Dec-08 10:17 
krishnakumartm wrote:
is there any better way to handle these type of situation


Yes, like:

if (ret)
    ret = foo1();
 
if (ret)
    ret = foo2();
 
if (ret)
    ret = foo3();
 
if (ret)
    ret = foo4();
If any of the function calls fail, none of the remaining ones will execute.

"Love people and use things, not love things and use people." - Unknown

"The brick walls are there for a reason...to stop the people who don't want it badly enough." - Randy Pausch


AnswerRe: Instead of using nested if-else Pin
bob169721-Dec-08 16:29
bob169721-Dec-08 16:29 
AnswerRe: Instead of using nested if-else Pin
sheshidar1-Dec-08 18:15
sheshidar1-Dec-08 18:15 
QuestionUsing "extern" Pin
krishnakumartm1-Dec-08 4:05
krishnakumartm1-Dec-08 4:05 
AnswerRe: Using "extern" Pin
Code-o-mat1-Dec-08 4:08
Code-o-mat1-Dec-08 4:08 
GeneralRe: Using "extern" Pin
krishnakumartm1-Dec-08 4:17
krishnakumartm1-Dec-08 4:17 
GeneralRe: Using "extern" Pin
Code-o-mat1-Dec-08 4:53
Code-o-mat1-Dec-08 4:53 
AnswerRe: Using "extern" Pin
CPallini1-Dec-08 5:41
mveCPallini1-Dec-08 5:41 
QuestionFocus rectangle on CDialogBox button Pin
J. Landsheer1-Dec-08 3:54
J. Landsheer1-Dec-08 3:54 
QuestionRe: Focus rectangle on CDialogBox button Pin
David Crow1-Dec-08 10:22
David Crow1-Dec-08 10:22 
AnswerRe: Focus rectangle on CDialogBox button Pin
J. Landsheer2-Dec-08 3:32
J. Landsheer2-Dec-08 3:32 
AnswerRe: Focus rectangle on CDialogBox button Pin
J. Landsheer9-Dec-08 2:34
J. Landsheer9-Dec-08 2:34 
Questionhow to give gray color Pin
Member 46556851-Dec-08 2:13
Member 46556851-Dec-08 2:13 
QuestionRe: how to give gray color Pin
CPallini1-Dec-08 2:23
mveCPallini1-Dec-08 2:23 
AnswerRe: how to give gray color Pin
Member 46556851-Dec-08 3:12
Member 46556851-Dec-08 3:12 
GeneralRe: how to give gray color Pin
CPallini1-Dec-08 3:20
mveCPallini1-Dec-08 3:20 
AnswerRe: how to give gray color Pin
SandipG 1-Dec-08 3:20
SandipG 1-Dec-08 3:20 
AnswerRe: how to give gray color Pin
Alan Balkany1-Dec-08 4:04
Alan Balkany1-Dec-08 4:04 

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.