Click here to Skip to main content
15,915,324 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionMenu in a MDI app (MFC 7.1) Pin
AkiraOne17-Jul-06 3:57
AkiraOne17-Jul-06 3:57 
AnswerRe: Menu in a MDI app (MFC 7.1) Pin
Nibu babu thomas17-Jul-06 18:28
Nibu babu thomas17-Jul-06 18:28 
GeneralRe: Menu in a MDI app (MFC 7.1) Pin
AkiraOne17-Jul-06 20:29
AkiraOne17-Jul-06 20:29 
QuestionBifurcating data in the form of nodes tobe stored in Tree Control Pin
ANAND JOSHI17-Jul-06 3:23
ANAND JOSHI17-Jul-06 3:23 
AnswerRe: Bifurcating data in the form of nodes tobe stored in Tree Control Pin
led mike17-Jul-06 7:26
led mike17-Jul-06 7:26 
QuestionNeed Help with Custom ListCtrl [modified] Pin
Jethro6317-Jul-06 3:13
Jethro6317-Jul-06 3:13 
QuestionHow to find the used memory? Pin
bosfan17-Jul-06 3:00
bosfan17-Jul-06 3:00 
AnswerRe: How to find the used memory? Pin
earl17-Jul-06 4:48
earl17-Jul-06 4:48 
QuestionReplacing my Menu with Default Menu of CFomView Pin
Uday Janaswamy17-Jul-06 2:30
Uday Janaswamy17-Jul-06 2:30 
AnswerRe: Replacing my Menu with Default Menu of CFomView Pin
*Dreamz17-Jul-06 3:09
*Dreamz17-Jul-06 3:09 
GeneralRe: Replacing my Menu with Default Menu of CFomView Pin
Uday Janaswamy17-Jul-06 3:25
Uday Janaswamy17-Jul-06 3:25 
GeneralRe: Replacing my Menu with Default Menu of CFomView Pin
*Dreamz17-Jul-06 3:34
*Dreamz17-Jul-06 3:34 
QuestionPorting C++ code from linux to Windows Pin
learning_a_lot17-Jul-06 2:14
learning_a_lot17-Jul-06 2:14 
AnswerRe: Porting C++ code from linux to Windows Pin
Cedric Moonen17-Jul-06 2:31
Cedric Moonen17-Jul-06 2:31 
AnswerRe: Porting C++ code from linux to Windows [modified] Pin
markkuk17-Jul-06 2:34
markkuk17-Jul-06 2:34 
GeneralRe: Porting C++ code from linux to Windows Pin
learning_a_lot17-Jul-06 4:52
learning_a_lot17-Jul-06 4:52 
AnswerRe: Porting C++ code from linux to Windows Pin
Rilhas21-Jul-06 13:10
Rilhas21-Jul-06 13:10 
I have found some problems in porting LINUX to WIN32 that contradict things that have been stated here. Specifically, the general idea of what is ANSI varies from person to person. The main problem I found is in these situations:

void some_function(char* string, long string_size) {
char buffer[string_size+1];
strcpy(buffer, string);
...
}

This code typically compiles with GCC, but not in WIN32 because "string_size" is not a constant. Technically, there is no real reason for this code not to compile, since it is perfectly possible to generate machine code for these kinds of instructions. However, I don't know how to get it to compile in WIN32. So, I find these compilations errors, and change them to something like:

void some_function(char* string, long string_size) {
char buffer[MAX_STRING_SIZE+1];
MyAssertSize(string_size, MAX_STRING_SIZE);
strcpy(buffer, string);
...
}

The MAX_STRING_SIZE is defined to be the maximum string size, and the MyAssertSize() is a macro (#define) that generates a controlled error if the requested size happens to be larger than the defined value.

Anyway, these are the hardest problems I have found. But, in general, you can expect code to compile but also expect tons of wornings. I have grown acustomed to living with them.

I hope this helps,
Rilhas



Questionhow to print from MFC to command Line Pin
kanna_p17-Jul-06 1:56
kanna_p17-Jul-06 1:56 
AnswerRe: how to print from MFC to command Line Pin
see me17-Jul-06 2:03
see me17-Jul-06 2:03 
QuestionRe: how to print from MFC to command Line Pin
David Crow17-Jul-06 2:40
David Crow17-Jul-06 2:40 
AnswerRe: how to print from MFC to command Line Pin
Monty217-Jul-06 3:08
Monty217-Jul-06 3:08 
AnswerRe: how to print from MFC to command Line Pin
kanna_p17-Jul-06 17:47
kanna_p17-Jul-06 17:47 
GeneralRe: how to print from MFC to command Line Pin
David Crow18-Jul-06 2:38
David Crow18-Jul-06 2:38 
AnswerRe: how to print from MFC to command Line Pin
earl17-Jul-06 4:50
earl17-Jul-06 4:50 
QuestionHINSTANCE for DLL Pin
Manjunath S17-Jul-06 1:50
Manjunath S17-Jul-06 1:50 

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.