Click here to Skip to main content
15,922,574 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Is this function in the windows98 support? Pin
Alice8012-Jul-03 23:51
Alice8012-Jul-03 23:51 
GeneralRe: Is this function in the windows98 support? Pin
Ryan Binns13-Jul-03 0:07
Ryan Binns13-Jul-03 0:07 
Questionhow I can insert these unicode characters rightly? Pin
Alice8012-Jul-03 16:54
Alice8012-Jul-03 16:54 
AnswerRe: how I can insert these unicode characters rightly? Pin
Anthony_Yio15-Jul-03 1:16
Anthony_Yio15-Jul-03 1:16 
GeneralRe: how I can insert these unicode characters rightly? Pin
Alice8015-Jul-03 1:37
Alice8015-Jul-03 1:37 
QuestionCan anybody say why no data gets shown? Pin
WREY12-Jul-03 14:23
WREY12-Jul-03 14:23 
AnswerRe: Can anybody say why no data gets shown? Pin
Michael Dunn12-Jul-03 16:24
sitebuilderMichael Dunn12-Jul-03 16:24 
GeneralRe: Can anybody say why no data gets shown? Pin
WREY12-Jul-03 17:54
WREY12-Jul-03 17:54 
Thank you for your insightful reply. However, while I'm happy to report that with the changes made (directly due to the points you made), data has now begun displaying. That's the good news!

The bad news is that they're garbage!

Here is the new code:

ostream& operator<< (ostream& output, const IData& idata)
{
	char Bufr[200] = " ";
	char* Ptr_fm[] = { idata.str, idata.pO, idata.pGH, idata.pIntrm };
	int i, Dec_fm[] = { idata.wrdlen, idata.lvlcnt, idata.ltrcnt };

	i  = sprintf(Bufr,   "\tstr:         0x%x\n",	*Ptr_fm);
	i += sprintf(Bufr+i, "\tOutput:      0x%x\n",	*(Ptr_fm+1));
	i += sprintf(Bufr+i, "\tGrp Hold:    0x%x\n",	*(Ptr_fm+2));
	i += sprintf(Bufr+i, "\tInterim:     0x%x\n",	*(Ptr_fm+3));
	i += sprintf(Bufr+i, "\tWord len:    %d\n",   *(Dec_fm);
	i += sprintf(Bufr+i, "\tLevel cnt:   %d\n",	*(Dec_fm+1));
	i += sprintf(Bufr+i, "\tLetter cnt:  %d\n",	*(Dec_fm+2));

	printf(" *******\n %s\n", Bufr);

	output<< idata;
	return output;
}

=========================================

Perhaps, helpful to mention is that just before the "for" loop is entered, the structure is instantiated to:

IData idata;

and upon entering the loop, the structure is initialized with data that are already present in the variables to which it is being initialized.

Right after those initializations take place, this is the statement that follows:

cout<< "\n\n ^^^ " << idata <
GeneralRe: Can anybody say why no data gets shown? Pin
PJ Arends12-Jul-03 18:03
professionalPJ Arends12-Jul-03 18:03 
GeneralRe: Can anybody say why no data gets shown? Pin
WREY12-Jul-03 18:20
WREY12-Jul-03 18:20 
GeneralRe: Can anybody say why no data gets shown? Pin
Michael Dunn12-Jul-03 18:37
sitebuilderMichael Dunn12-Jul-03 18:37 
GeneralRe: Can anybody say why no data gets shown? Pin
Mike Dimmick13-Jul-03 1:44
Mike Dimmick13-Jul-03 1:44 
GeneralRe: Can anybody say why no data gets shown? Pin
WREY13-Jul-03 4:28
WREY13-Jul-03 4:28 
GeneralProblem by getting new object in GDI+, Help me. Pin
Behzad Ebrahimi12-Jul-03 9:08
Behzad Ebrahimi12-Jul-03 9:08 
GeneralRe: Problem by getting new object in GDI+, Help me. Pin
Neville Franks12-Jul-03 13:02
Neville Franks12-Jul-03 13:02 
GeneralRe: Problem by getting new object in GDI+, Help me. Pin
PJ Arends12-Jul-03 16:30
professionalPJ Arends12-Jul-03 16:30 
Generalpush_back, push_front Pin
DaveE9th12-Jul-03 8:00
DaveE9th12-Jul-03 8:00 
GeneralRe: push_back, push_front Pin
Mike Dimmick12-Jul-03 8:17
Mike Dimmick12-Jul-03 8:17 
GeneralRe: push_back, push_front Pin
DaveE9th12-Jul-03 8:32
DaveE9th12-Jul-03 8:32 
GeneralRe: push_back, push_front Pin
Mike Dimmick12-Jul-03 8:54
Mike Dimmick12-Jul-03 8:54 
GeneralRe: push_back, push_front Pin
DaveE9th12-Jul-03 17:40
DaveE9th12-Jul-03 17:40 
GeneralOffsets and stuff Pin
Anonymous12-Jul-03 7:48
Anonymous12-Jul-03 7:48 
GeneralRe: Offsets and stuff Pin
Mike Dimmick12-Jul-03 8:27
Mike Dimmick12-Jul-03 8:27 
GeneralRe: Offsets and stuff Pin
Toni7813-Jul-03 11:08
Toni7813-Jul-03 11:08 
QuestionCan anyone help me?? Pin
Snyp12-Jul-03 6:47
Snyp12-Jul-03 6:47 

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.