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

C / C++ / MFC

 
GeneralRe: Fill array Pin
AbhiHcl6-Aug-10 0:23
AbhiHcl6-Aug-10 0:23 
GeneralRe: Fill array Pin
bleedingfingers6-Aug-10 0:25
bleedingfingers6-Aug-10 0:25 
GeneralRe: Fill array Pin
bleedingfingers6-Aug-10 1:44
bleedingfingers6-Aug-10 1:44 
AnswerRe: Fill array Pin
_AnsHUMAN_ 6-Aug-10 0:13
_AnsHUMAN_ 6-Aug-10 0:13 
GeneralRe: Fill array Pin
AbhiHcl6-Aug-10 0:24
AbhiHcl6-Aug-10 0:24 
AnswerRe: Fill array Pin
Sauro Viti6-Aug-10 0:34
professionalSauro Viti6-Aug-10 0:34 
GeneralRe: Fill array Pin
AbhiHcl6-Aug-10 0:49
AbhiHcl6-Aug-10 0:49 
AnswerRe: Fill array [modified] Pin
Sauro Viti6-Aug-10 1:06
professionalSauro Viti6-Aug-10 1:06 
Try to work around this snippet:

C++
char *szStr = "2,aaa\r\n3,bbb\r\n4,ccc\r\n5,ddd\r\n6,eee\r\n";

char *token1 = strtok(szStr, ",");
char *token2 = strtok(NULL, "\r\n");

// Get the first pair number/text from token1 and token2

int n = 1;

while (token1 != NULL && token2 != NULL && n < 5)
{
   token1 = strtok(NULL, ",");
   token2 = strtok(NULL, "\r\n");
   
   // Get the n-th pair number/text from token1 and token2

   n++;
}


modified on Friday, August 6, 2010 7:49 AM

GeneralRe: Fill array Pin
bleedingfingers6-Aug-10 1:36
bleedingfingers6-Aug-10 1:36 
GeneralRe: Fill array Pin
Sauro Viti6-Aug-10 1:51
professionalSauro Viti6-Aug-10 1:51 
GeneralRe: Fill array Pin
Sauro Viti6-Aug-10 2:19
professionalSauro Viti6-Aug-10 2:19 
GeneralRe: Fill array Pin
David Crow6-Aug-10 2:55
David Crow6-Aug-10 2:55 
QuestionPermanent popup menu (aka list control) c++, MFC Pin
arthur89kim5-Aug-10 23:44
arthur89kim5-Aug-10 23:44 
AnswerRe: Permanent popup menu (aka list control) c++, MFC Pin
Sauro Viti5-Aug-10 23:53
professionalSauro Viti5-Aug-10 23:53 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
arthur89kim6-Aug-10 0:09
arthur89kim6-Aug-10 0:09 
AnswerRe: Permanent popup menu (aka list control) c++, MFC Pin
Sauro Viti6-Aug-10 0:27
professionalSauro Viti6-Aug-10 0:27 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
arthur89kim6-Aug-10 0:35
arthur89kim6-Aug-10 0:35 
AnswerRe: Permanent popup menu (aka list control) c++, MFC Pin
Richard MacCutchan5-Aug-10 23:53
mveRichard MacCutchan5-Aug-10 23:53 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
arthur89kim6-Aug-10 0:16
arthur89kim6-Aug-10 0:16 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
Richard MacCutchan6-Aug-10 0:48
mveRichard MacCutchan6-Aug-10 0:48 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
arthur89kim6-Aug-10 4:16
arthur89kim6-Aug-10 4:16 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
Richard MacCutchan6-Aug-10 4:40
mveRichard MacCutchan6-Aug-10 4:40 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
arthur89kim7-Aug-10 21:36
arthur89kim7-Aug-10 21:36 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
Richard MacCutchan8-Aug-10 0:54
mveRichard MacCutchan8-Aug-10 0:54 
GeneralRe: Permanent popup menu (aka list control) c++, MFC Pin
arthur89kim8-Aug-10 15:25
arthur89kim8-Aug-10 15:25 

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.