Click here to Skip to main content
14,775,466 members
Home » Discussions » C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Popularity Of C among developer Pin
Richard MacCutchan17-Apr-19 3:48
mveRichard MacCutchan17-Apr-19 3:48 
GeneralRe: Popularity Of C among developer Pin
David Crow17-Apr-19 4:09
MemberDavid Crow17-Apr-19 4:09 
GeneralRe: Popularity Of C among developer Pin
Richard MacCutchan17-Apr-19 4:27
mveRichard MacCutchan17-Apr-19 4:27 
QuestionRe: Popularity Of C among developer Pin
David Crow17-Apr-19 4:50
MemberDavid Crow17-Apr-19 4:50 
AnswerRe: Popularity Of C among developer Pin
Richard MacCutchan17-Apr-19 7:19
mveRichard MacCutchan17-Apr-19 7:19 
GeneralRe: Popularity Of C among developer Pin
David Crow17-Apr-19 7:27
MemberDavid Crow17-Apr-19 7:27 
GeneralRe: Popularity Of C among developer Pin
Richard MacCutchan17-Apr-19 7:35
mveRichard MacCutchan17-Apr-19 7:35 
QuestionRe: Popularity Of C among developer Pin
David Crow17-Apr-19 8:00
MemberDavid Crow17-Apr-19 8:00 
Richard MacCutchan wrote:
At the risk of repeating myself, that is not going to work.
Please repeat, because I really want to know what I'm doing wrong.

Richard MacCutchan wrote:
...and not provide the struct definition to the user...
In the sample code that I showed, the user would have access to the definition of the Car struct (which could obviously contain more public members), and to the declaration of the CarPrivate struct. CarPrivate would be fully implemented/defined in the LIB file.

Richard MacCutchan wrote:
But that means the user cannot allocate any space for the data in the first place.
Are you referring to the user doing something like:
struct Car* car = some_method_to_create_car();
Similar to the GetYear() function shown earlier, the some_method_to_create_car() function (that I didn't bother implementing) would have access to the CarPrivate members.

"One man's wage rise is another man's price increase." - Harold Wilson

"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

"You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles


AnswerRe: Popularity Of C among developer Pin
Richard MacCutchan17-Apr-19 22:30
mveRichard MacCutchan17-Apr-19 22:30 
AnswerRe: Popularity Of C among developer Pin
John R. Shaw19-Apr-19 9:47
MemberJohn R. Shaw19-Apr-19 9:47 
GeneralRe: Popularity Of C among developer Pin
jschell21-Apr-19 8:46
Memberjschell21-Apr-19 8:46 
AnswerRe: Popularity Of C among developer Pin
jschell21-Apr-19 8:35
Memberjschell21-Apr-19 8:35 
QuestionGet menu color in MFC feature pack Pin
_Flaviu14-Apr-19 0:26
Member_Flaviu14-Apr-19 0:26 
Question"Debug Assertion Failed at line: 252 in viewcore.CPP" Pin
manoharbalu10-Apr-19 19:21
Membermanoharbalu10-Apr-19 19:21 
AnswerRe: "Debug Assertion Failed at line: 252 in viewcore.CPP" Pin
Victor Nijegorodov10-Apr-19 21:58
MemberVictor Nijegorodov10-Apr-19 21:58 
QuestionRe: "Debug Assertion Failed at line: 252 in viewcore.CPP" Pin
David Crow11-Apr-19 11:33
MemberDavid Crow11-Apr-19 11:33 
QuestionProblem when I run the application using cntrl+F5. Wintech OPC DLL Pin
D.Manivelan8-Apr-19 5:02
MemberD.Manivelan8-Apr-19 5:02 
AnswerRe: Problem when I run the application using cntrl+F5. Wintech OPC DLL Pin
11917640 Member 9-Apr-19 23:57
Member11917640 Member 9-Apr-19 23:57 
GeneralRe: Problem when I run the application using cntrl+F5. Wintech OPC DLL Pin
D.Manivelan10-Apr-19 20:04
MemberD.Manivelan10-Apr-19 20:04 
GeneralRe: Problem when I run the application using cntrl+F5. Wintech OPC DLL Pin
Victor Nijegorodov10-Apr-19 21:55
MemberVictor Nijegorodov10-Apr-19 21:55 
QuestionClass as memebrs of other classes : Create a constructor that takes all data Pin
desanti6-Apr-19 8:09
Memberdesanti6-Apr-19 8:09 
AnswerRe: Class as memebrs of other classes : Create a constructor that takes all data Pin
k50546-Apr-19 10:40
mvek50546-Apr-19 10:40 
GeneralRe: Class as memebrs of other classes : Create a constructor that takes all data Pin
Stefan_Lang8-Apr-19 22:51
mveStefan_Lang8-Apr-19 22:51 
AnswerRe: Class as memebrs of other classes : Create a constructor that takes all data Pin
Gerry Schmitz6-Apr-19 11:36
mveGerry Schmitz6-Apr-19 11:36 
AnswerRe: Class as memebrs of other classes : Create a constructor that takes all data Pin
jschell7-Apr-19 9:53
Memberjschell7-Apr-19 9:53 

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.