Click here to Skip to main content
15,893,564 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerDon't answer this person. Pin
leckey13-Jun-07 7:58
leckey13-Jun-07 7:58 
AnswerRe: What is C#? Pin
Hamid_RT13-Jun-07 8:54
Hamid_RT13-Jun-07 8:54 
Questionsending data Pin
barbara_j_jenson13-Jun-07 6:38
barbara_j_jenson13-Jun-07 6:38 
AnswerRe: sending data Pin
Mark Salsbery13-Jun-07 7:03
Mark Salsbery13-Jun-07 7:03 
GeneralRe: sending data Pin
barbara_j_jenson14-Jun-07 1:29
barbara_j_jenson14-Jun-07 1:29 
Questionembedded resource in DLL v/s static library Pin
act_x13-Jun-07 6:20
act_x13-Jun-07 6:20 
AnswerRe: embedded resource in DLL v/s static library Pin
David Crow13-Jun-07 6:31
David Crow13-Jun-07 6:31 
QuestionCString concatenation problem Pin
penny black13-Jun-07 6:12
penny black13-Jun-07 6:12 
New to VC++, working with 6.0

Trying to read a text file one character at a time. If program finds a comma in text file, it stops and creates a string out of all the preceding characters. No problem reading the file or recognizing the comma. The program won't concatenate the chars into one string.

Here's the code:
char buffer[1];
char cur_char = NULL;
CString cur_data;
UINT bytesread;
do
{
    cur_data += cur_char;
    bytesread=radardata.Read(buffer,1);
    cur_char=buffer[0];
}
while (cur_char != ',');


Every time I run it, cur_data ends up NULL. Here's what else I've tried with the same result:
cur_data = cur_data + CString(cur_char);
cur_data = CString(cur_data) + CString(cur_char)


Thanks in advance!
AnswerRe: CString concatenation problem Pin
Arman S.13-Jun-07 6:18
Arman S.13-Jun-07 6:18 
GeneralRe: CString concatenation problem Pin
penny black14-Jun-07 3:34
penny black14-Jun-07 3:34 
QuestionRe: CString concatenation problem Pin
David Crow13-Jun-07 6:21
David Crow13-Jun-07 6:21 
AnswerRe: CString concatenation problem Pin
penny black14-Jun-07 3:36
penny black14-Jun-07 3:36 
Questionproblem with ifstream Pin
Yonggoo13-Jun-07 5:42
Yonggoo13-Jun-07 5:42 
AnswerRe: problem with ifstream Pin
David Crow13-Jun-07 5:57
David Crow13-Jun-07 5:57 
GeneralRe: problem with ifstream(more details?) Pin
Yonggoo13-Jun-07 6:03
Yonggoo13-Jun-07 6:03 
GeneralRe: problem with ifstream(more details?) Pin
David Crow13-Jun-07 6:16
David Crow13-Jun-07 6:16 
QuestionVisual Studio debugger telling me wrong information Pin
Cyrilix13-Jun-07 5:35
Cyrilix13-Jun-07 5:35 
QuestionRe: Visual Studio debugger telling me wrong information Pin
David Crow13-Jun-07 6:19
David Crow13-Jun-07 6:19 
AnswerRe: Visual Studio debugger telling me wrong information Pin
Cyrilix13-Jun-07 6:35
Cyrilix13-Jun-07 6:35 
AnswerProblem Fixed -- optimization (/O2) causes these problems Pin
Cyrilix13-Jun-07 6:49
Cyrilix13-Jun-07 6:49 
GeneralRe: Problem Fixed -- optimization (/O2) causes these problems Pin
David Crow13-Jun-07 6:53
David Crow13-Jun-07 6:53 
GeneralRe: Problem Fixed -- optimization (/O2) causes these problems Pin
Cyrilix13-Jun-07 7:02
Cyrilix13-Jun-07 7:02 
Questionutyutyuytuutyutyutyuutyutyutyutyutyutyu/,.//,./, Pin
suchon_phuong13-Jun-07 5:33
suchon_phuong13-Jun-07 5:33 
AnswerRe: utyutyuytuutyutyutyuutyutyutyutyutyutyu/,.//,./, Pin
Cedric Moonen13-Jun-07 7:11
Cedric Moonen13-Jun-07 7:11 
QuestionDraw a cube Pin
gentleguy13-Jun-07 5:18
gentleguy13-Jun-07 5:18 

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.