Click here to Skip to main content
16,015,166 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Find at lease 8 errors Pin
Gary R. Wheeler14-Mar-06 2:39
Gary R. Wheeler14-Mar-06 2:39 
AnswerRe: Find at lease 8 errors Pin
Gary R. Wheeler14-Mar-06 2:42
Gary R. Wheeler14-Mar-06 2:42 
GeneralRe: Find at lease 8 errors Pin
LiYS14-Mar-06 3:09
LiYS14-Mar-06 3:09 
GeneralRe: Find at lease 8 errors Pin
Gary R. Wheeler14-Mar-06 5:41
Gary R. Wheeler14-Mar-06 5:41 
AnswerRe: Find at lease 8 errors Pin
David Crow14-Mar-06 2:48
David Crow14-Mar-06 2:48 
GeneralRe: Find at lease 8 errors Pin
LiYS14-Mar-06 3:12
LiYS14-Mar-06 3:12 
AnswerRe: Find at lease 8 errors Pin
Prakash Nadar14-Mar-06 5:31
Prakash Nadar14-Mar-06 5:31 
QuestionError in adding values to List from File. Pin
Anu_Bala14-Mar-06 0:40
Anu_Bala14-Mar-06 0:40 
BOOL CPerformanceGraph::ReadFromFile()
{
CFile fp;
CPtrList tempList;
CString szFileName= "c:\\PerfGraph.txt";

if(!fp.Open(szFileName,CFile::modeRead))
{
MessageBox( "Unable to open file for Performance Graph Configuration");
return FALSE;
}

pGraphList.RemoveAll();
CPerfGraph *oPerfGraph = new CPerfGraph();

while(fp.Read( oPerfGraph, sizeof( class CPerfGraph )))
{
//for checking
int n;
n=oPerfGraph->No_of_Points;
char temp[10];
strcpy(temp,oPerfGraph->Id);
strcpy(temp,oPerfGraph->TagX);
//end of checking
tempList.AddTail(oPerfGraph);

}


POSITION Pos = tempList.GetHeadPosition();

while(Pos)
{
CPerfGraph *oTemp=(CPerfGraph *)tempList.GetAt(Pos); //for checking
CString mTagX = oTemp->TagX;
CString mTagY = oTemp->TagY;
//end of checking
tempList.GetNext(Pos);
}


fp.Close();
return TRUE;


}

This is my coding...Im reading datas from File and put it into CPtrList.But It doesn't get adding properly.
I have two set of values as graph1 and graph 2.
But it adds only the last Graph2 value.

How can i get the Graph 1 value.

I think im using the correct way to add the file data in to List.

Kindly give me solution...

AnswerRe: Error in adding values to List from File. Pin
Gary R. Wheeler14-Mar-06 1:19
Gary R. Wheeler14-Mar-06 1:19 
AnswerRe: Error in adding values to List from File. Pin
David Crow14-Mar-06 2:55
David Crow14-Mar-06 2:55 
QuestionProgram crashing on Drop Pin
Anil_vvs14-Mar-06 0:33
Anil_vvs14-Mar-06 0:33 
AnswerRe: Program crashing on Drop Pin
Michael Dunn14-Mar-06 8:43
sitebuilderMichael Dunn14-Mar-06 8:43 
GeneralRe: Program crashing on Drop Pin
Anil_vvs15-Mar-06 18:18
Anil_vvs15-Mar-06 18:18 
QuestionRemote Database Pin
J512198214-Mar-06 0:23
J512198214-Mar-06 0:23 
Questionwhy the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
phijophlip14-Mar-06 0:00
phijophlip14-Mar-06 0:00 
AnswerRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
Naveen14-Mar-06 0:23
Naveen14-Mar-06 0:23 
AnswerRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
Nibu babu thomas14-Mar-06 0:24
Nibu babu thomas14-Mar-06 0:24 
AnswerRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
Phil.Benson14-Mar-06 0:33
professionalPhil.Benson14-Mar-06 0:33 
AnswerRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
Hamid_RT14-Mar-06 0:46
Hamid_RT14-Mar-06 0:46 
GeneralRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
jhwurmbach14-Mar-06 2:34
jhwurmbach14-Mar-06 2:34 
GeneralRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
David Crow14-Mar-06 3:01
David Crow14-Mar-06 3:01 
AnswerRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
David Crow14-Mar-06 3:00
David Crow14-Mar-06 3:00 
GeneralRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
Phil.Benson14-Mar-06 3:04
professionalPhil.Benson14-Mar-06 3:04 
GeneralRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
David Crow14-Mar-06 3:23
David Crow14-Mar-06 3:23 
GeneralRe: why the value enter the IDC_EDIT1 is not shown in IDC_EDIT2? Pin
Phil.Benson14-Mar-06 3:42
professionalPhil.Benson14-Mar-06 3:42 

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.