Click here to Skip to main content
15,888,968 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Simple FTP Client Pin
dellthinker2-Nov-07 6:53
dellthinker2-Nov-07 6:53 
GeneralRe: Simple FTP Client Pin
Peter Weyzen2-Nov-07 7:32
Peter Weyzen2-Nov-07 7:32 
GeneralRe: Simple FTP Client Pin
Bram van Kampen2-Nov-07 3:22
Bram van Kampen2-Nov-07 3:22 
QuestionWizard 2000 Style Wizard Pin
Larry Mills Sr1-Nov-07 7:14
Larry Mills Sr1-Nov-07 7:14 
QuestionCan I pass through a variable number of arguments to another function? Pin
jp-mocs1-Nov-07 6:25
jp-mocs1-Nov-07 6:25 
AnswerRe: Can I pass through a variable number of arguments to another function? Pin
Luc Pattyn1-Nov-07 7:12
sitebuilderLuc Pattyn1-Nov-07 7:12 
AnswerRe: Can I pass through a variable number of arguments to another function? Pin
Chris Losinger1-Nov-07 7:50
professionalChris Losinger1-Nov-07 7:50 
GeneralRe: Can I pass through a variable number of arguments to another function? Pin
jp-mocs1-Nov-07 12:17
jp-mocs1-Nov-07 12:17 
Ok, I modified the csPrintf (the first one that passes the vars to the second) to look like this:

void cScreen::csPrintf(char *format, ...){
va_list argp;
char buffer[1024] = { 0 };

va_start( argp, format );

vsprintf_s( buffer, sizeof( buffer ), format, argp );

va_end(argp);

cScreenWindow tempWin = getWin(printWin);
tempWin.cswPrintf(buffer);

} // end of cScreen::csPrintf

This seems to work fine in most instances... curiously enough, it fails on one... calling csr.csPrintf(...) from the main routine looks like this:

csr.csPrintf("this is to test string function passthrough");
csr.csPrintf("char %c and int %d see if it works!", 'v', 10);
csr.csPrintf("string %s and hex %x see if it works!", "<test>", '\x00');
csr.csPrintf("test non-valid %y", 9);

The new routine above successfully calls tempWin.cswPrintf(buffer) in all instances except, curiously, the last. I have to think that the problem therefore lies in cswPrintf, except the debug keeps telling me it's in csPrintf. Oh well... wouldn't be the first time a computer lied to me...

Anyway, this (for the most part) works, and THAT was the main thing...

Thanks for the assist... I wanted to post to let you know it helped, and so anyone else reading could see how it wound out...

=->Mocs<-=

GeneralRe: Can I pass through a variable number of arguments to another function? Pin
jp-mocs2-Nov-07 5:44
jp-mocs2-Nov-07 5:44 
QuestionOn selection a word in CEdit, which messages windows return? Pin
Gofur Halmurat1-Nov-07 6:19
Gofur Halmurat1-Nov-07 6:19 
AnswerRe: On selection a word in CEdit, which messages windows return? Pin
Maximilien1-Nov-07 6:23
Maximilien1-Nov-07 6:23 
GeneralRe: On selection a word in CEdit, which messages windows return? Pin
Gofur Halmurat1-Nov-07 6:34
Gofur Halmurat1-Nov-07 6:34 
AnswerRe: On selection a word in CEdit, which messages windows return? Pin
Mark Salsbery1-Nov-07 7:01
Mark Salsbery1-Nov-07 7:01 
GeneralRe: On selection a word in CEdit, which messages windows return? Pin
Gofur Halmurat1-Nov-07 7:24
Gofur Halmurat1-Nov-07 7:24 
GeneralRe: On selection a word in CEdit, which messages windows return? Pin
Mark Salsbery1-Nov-07 7:54
Mark Salsbery1-Nov-07 7:54 
GeneralRe: On selection a word in CEdit, which messages windows return? Pin
Gofur Halmurat1-Nov-07 9:29
Gofur Halmurat1-Nov-07 9:29 
GeneralRe: On selection a word in CEdit, which messages windows return? Pin
Mark Salsbery1-Nov-07 10:51
Mark Salsbery1-Nov-07 10:51 
QuestionBandwidth Monitor Pin
Alisdair Piercy1-Nov-07 5:25
Alisdair Piercy1-Nov-07 5:25 
AnswerRe: Bandwidth Monitor Pin
led mike1-Nov-07 6:06
led mike1-Nov-07 6:06 
GeneralRe: Bandwidth Monitor Pin
Alisdair Piercy1-Nov-07 6:10
Alisdair Piercy1-Nov-07 6:10 
GeneralRe: Bandwidth Monitor Pin
led mike1-Nov-07 6:36
led mike1-Nov-07 6:36 
Questionunresolved external ... CInvalidArgException Pin
bruccutler1-Nov-07 5:05
bruccutler1-Nov-07 5:05 
AnswerRe: unresolved external ... CInvalidArgException Pin
led mike1-Nov-07 5:34
led mike1-Nov-07 5:34 
QuestionRe: unresolved external ... CInvalidArgException Pin
Chris Meech1-Nov-07 7:28
Chris Meech1-Nov-07 7:28 
AnswerRe: unresolved external ... CInvalidArgException Pin
bruccutler12-Nov-07 15:29
bruccutler12-Nov-07 15:29 

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.