Click here to Skip to main content
15,895,799 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: ADO in MFC.....getting problems Pin
AmbiguousName16-Jan-11 4:30
AmbiguousName16-Jan-11 4:30 
AnswerRe: ADO in MFC.....getting problems Pin
PJ Arends16-Jan-11 11:55
professionalPJ Arends16-Jan-11 11:55 
Questionoperator ":" new for me in C++ Pin
aesthetic.crazy16-Jan-11 0:53
aesthetic.crazy16-Jan-11 0:53 
AnswerRe: operator ":" new for me in C++ Pin
Richard MacCutchan16-Jan-11 1:28
mveRichard MacCutchan16-Jan-11 1:28 
GeneralRe: operator ":" new for me in C++ Pin
aesthetic.crazy16-Jan-11 6:51
aesthetic.crazy16-Jan-11 6:51 
GeneralRe: operator ":" new for me in C++ Pin
Richard MacCutchan16-Jan-11 7:04
mveRichard MacCutchan16-Jan-11 7:04 
AnswerRe: operator ":" new for me in C++ PinPopular
Iain Clarke, Warrior Programmer16-Jan-11 1:36
Iain Clarke, Warrior Programmer16-Jan-11 1:36 
AnswerRe: operator ":" new for me in C++ PinPopular
Aescleal16-Jan-11 9:01
Aescleal16-Jan-11 9:01 
In the case you're asking about the colon marks the start of an initialiser list. These describe how to initialise a class's base class or member variables. Each element of the initialiser list has the syntax:

A( x, ... )


where A is either the name of the base class or the name of the member variable to be initialised and x,... is the list of arguments to the constructor of the base class or member.

I'd suggest grabbing a copy of "The C++ Programming Language" by Bjarne Stroustrup. He describes the initialisation of member objects and base classes in loads of detail in part 2 of the book. And explains why you'd prefer to write initialisers rather than making assignments in the body of a constructor.

Cheers,

Ash
AnswerRe: operator ":" new for me in C++ Pin
moemass17-Jan-11 3:12
moemass17-Jan-11 3:12 
QuestionHow to get computer color setting? Pin
includeh1015-Jan-11 20:37
includeh1015-Jan-11 20:37 
AnswerRe: How to get computer color setting? Pin
Andrew Brock15-Jan-11 20:53
Andrew Brock15-Jan-11 20:53 
GeneralRe: How to get computer color setting? Pin
includeh1016-Jan-11 2:47
includeh1016-Jan-11 2:47 
GeneralRe: How to get computer color setting? Pin
Andrew Brock16-Jan-11 2:51
Andrew Brock16-Jan-11 2:51 
QuestionSorting data using std::map or std::multimap Pin
cmacgowan15-Jan-11 14:19
cmacgowan15-Jan-11 14:19 
AnswerRe: Sorting data using std::map or std::multimap Pin
Andrew Brock15-Jan-11 18:08
Andrew Brock15-Jan-11 18:08 
GeneralRe: Sorting data using std::map or std::multimap Pin
cmacgowan16-Jan-11 11:01
cmacgowan16-Jan-11 11:01 
AnswerRe: Sorting data using std::map or std::multimap Pin
Aescleal16-Jan-11 6:10
Aescleal16-Jan-11 6:10 
GeneralRe: Sorting data using std::map or std::multimap Pin
cmacgowan16-Jan-11 11:02
cmacgowan16-Jan-11 11:02 
QuestionSoftware Keyboard Simulator Pin
RedDragon2k15-Jan-11 4:48
RedDragon2k15-Jan-11 4:48 
AnswerRe: Software Keyboard Simulator Pin
jschell15-Jan-11 10:02
jschell15-Jan-11 10:02 
AnswerRe: Software Keyboard Simulator Pin
Andrew Brock15-Jan-11 17:16
Andrew Brock15-Jan-11 17:16 
AnswerRe: Software Keyboard Simulator Pin
loyal ginger15-Jan-11 17:25
loyal ginger15-Jan-11 17:25 
GeneralRe: Software Keyboard Simulator Pin
RedDragon2k16-Jan-11 4:11
RedDragon2k16-Jan-11 4:11 
QuestionHow to Set Position where a Window will be minimised Pin
SoftwareDeveloperGoa15-Jan-11 4:42
SoftwareDeveloperGoa15-Jan-11 4:42 
AnswerRe: How to Set Position where a Window will be minimised Pin
Emilio Garavaglia15-Jan-11 7:09
Emilio Garavaglia15-Jan-11 7:09 

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.