Click here to Skip to main content
15,887,392 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionCopy a module Pin
Cyclone0220-Oct-06 0:24
Cyclone0220-Oct-06 0:24 
QuestionHow to resolve Run time Error ? Pin
zhang80060520-Oct-06 0:12
zhang80060520-Oct-06 0:12 
AnswerRe: How to resolve Run time Error ? Pin
prasad_som20-Oct-06 0:23
prasad_som20-Oct-06 0:23 
QuestionLive Redirection Pin
rupert_durans19-Oct-06 23:49
rupert_durans19-Oct-06 23:49 
QuestionHow to change Project settings by using MSDEV Automation. Pin
Jijo.Raj19-Oct-06 23:31
Jijo.Raj19-Oct-06 23:31 
QuestionWhen to declare variables in C/C++ ? Pin
Mr.Brainley19-Oct-06 23:26
Mr.Brainley19-Oct-06 23:26 
AnswerRe: When to declare variables in C/C++ ? Pin
Cedric Moonen19-Oct-06 23:31
Cedric Moonen19-Oct-06 23:31 
AnswerRe: When to declare variables in C/C++ ? Pin
prasad_som19-Oct-06 23:40
prasad_som19-Oct-06 23:40 
To add Cedric;
By declaring it at start, it will be in memory unnecessarily for longer time, when its required somewhere down in the code. So declare it when its necessary. And its always easy to track it in this case.

Mr.Brainley wrote:
And why is that different in C ?


Its by standard in C.


AnswerRe: When to declare variables in C/C++ ? Pin
Jonathan [Darka]19-Oct-06 23:43
professionalJonathan [Darka]19-Oct-06 23:43 
AnswerRe: When to declare variables in C/C++ ? Pin
Christian Graus20-Oct-06 0:59
protectorChristian Graus20-Oct-06 0:59 
GeneralRe: When to declare variables in C/C++ ? Pin
benjymous20-Oct-06 1:23
benjymous20-Oct-06 1:23 
AnswerRe: When to declare variables in C/C++ ? Pin
David Crow20-Oct-06 3:18
David Crow20-Oct-06 3:18 
QuestionProblem with IHTMLInputElement Pin
georgekjolly19-Oct-06 23:05
georgekjolly19-Oct-06 23:05 
AnswerRe: Problem with IHTMLInputElement Pin
prasad_som19-Oct-06 23:18
prasad_som19-Oct-06 23:18 
AnswerRe: Problem with IHTMLInputElement Pin
Hamid_RT20-Oct-06 0:06
Hamid_RT20-Oct-06 0:06 
QuestionOLEDATA.MSO Format Pin
Reuven Nisser19-Oct-06 22:56
Reuven Nisser19-Oct-06 22:56 
QuestionPush-like checkboxes in WinXP Pin
Kiomuto19-Oct-06 22:47
Kiomuto19-Oct-06 22:47 
AnswerRe: Push-like checkboxes in WinXP Pin
Hamid_RT20-Oct-06 7:12
Hamid_RT20-Oct-06 7:12 
GeneralRe: Push-like checkboxes in WinXP Pin
Kiomuto21-Oct-06 5:51
Kiomuto21-Oct-06 5:51 
Questionreturning const member data Pin
minkowski19-Oct-06 22:41
minkowski19-Oct-06 22:41 
AnswerRe: returning const member data Pin
Cedric Moonen19-Oct-06 23:00
Cedric Moonen19-Oct-06 23:00 
GeneralRe: returning const member data Pin
minkowski19-Oct-06 23:01
minkowski19-Oct-06 23:01 
GeneralRe: returning const member data Pin
Cedric Moonen19-Oct-06 23:12
Cedric Moonen19-Oct-06 23:12 
AnswerRe: returning const member data Pin
prasad_som19-Oct-06 23:06
prasad_som19-Oct-06 23:06 
GeneralRe: returning const member data Pin
minkowski19-Oct-06 23:16
minkowski19-Oct-06 23:16 

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.