Click here to Skip to main content
15,911,315 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: static variable Pin
George_George23-Aug-07 22:36
George_George23-Aug-07 22:36 
GeneralRe: static variable Pin
BadKarma23-Aug-07 23:24
BadKarma23-Aug-07 23:24 
GeneralRe: static variable Pin
George_George23-Aug-07 23:39
George_George23-Aug-07 23:39 
GeneralRe: static variable Pin
toxcct24-Aug-07 1:42
toxcct24-Aug-07 1:42 
GeneralRe: static variable Pin
George_George25-Aug-07 21:25
George_George25-Aug-07 21:25 
GeneralRe: static variable Pin
codeII24-Aug-07 1:49
codeII24-Aug-07 1:49 
GeneralRe: static variable Pin
George_George25-Aug-07 21:27
George_George25-Aug-07 21:27 
AnswerRe: static variable Pin
David Crow24-Aug-07 6:05
David Crow24-Aug-07 6:05 
GeneralRe: static variable Pin
George_George25-Aug-07 21:29
George_George25-Aug-07 21:29 
AnswerRe: static variable Pin
ghle26-Aug-07 3:42
ghle26-Aug-07 3:42 
GeneralRe: static variable Pin
George_George26-Aug-07 6:42
George_George26-Aug-07 6:42 
GeneralRe: static variable [modified] Pin
ghle26-Aug-07 10:00
ghle26-Aug-07 10:00 
GeneralRe: static variable Pin
George_George26-Aug-07 19:22
George_George26-Aug-07 19:22 
Questionregistry cleaner for window xp Pin
niki dutta23-Aug-07 18:26
niki dutta23-Aug-07 18:26 
AnswerRe: registry cleaner for window xp Pin
User 58385223-Aug-07 19:18
User 58385223-Aug-07 19:18 
AnswerRe: registry cleaner for window xp Pin
_AnsHUMAN_ 23-Aug-07 20:04
_AnsHUMAN_ 23-Aug-07 20:04 
AnswerRe: registry cleaner for window xp Pin
ThatsAlok23-Aug-07 20:11
ThatsAlok23-Aug-07 20:11 
AnswerPlease continue on the same thread !! Pin
toxcct23-Aug-07 21:57
toxcct23-Aug-07 21:57 
AnswerRe: registry cleaner for window xp Pin
Hamid_RT24-Aug-07 2:51
Hamid_RT24-Aug-07 2:51 
AnswerRe: registry cleaner for window xp Pin
David Crow24-Aug-07 6:18
David Crow24-Aug-07 6:18 
QuestionMFC Dialog I/O Pin
alberthyc23-Aug-07 17:53
alberthyc23-Aug-07 17:53 
AnswerRe: MFC Dialog I/O Pin
Nishad S23-Aug-07 21:21
Nishad S23-Aug-07 21:21 
AnswerRe: MFC Dialog I/O Pin
toxcct23-Aug-07 22:00
toxcct23-Aug-07 22:00 
GeneralRe: MFC Dialog I/O Pin
alberthyc24-Aug-07 4:01
alberthyc24-Aug-07 4:01 
AnswerRe: MFC Dialog I/O Pin
ghle26-Aug-07 11:00
ghle26-Aug-07 11:00 
alberthyc wrote:
4 rows with 5 edit box with each row.

Note: your example data is 5 rows with 5 edit boxes each.Blush | :O

First time getting data from a file, eh?;P

<br />
if( FileDlg.DoModal() == IDOK )<br />
{<br />
  if( f.Open(FileDlg.GetFileName(), CFile::modeRead) == FALSE )<br />
  {<br />
    return;<br />
  }<br />

// Quick & dirty
  char cBuffer[MAX_SIZE];
  if (f.GetLength() > sizeof(cBuffer))
  {
    AfxMessageBox("I theenk I need a beegger box!", MB_OK|MB_ICONERROR|MB_SETFOREGROUND);
    // Error handling
  } else {
    // Buffer the data if there is some
    if (f.Read(cBuffer, sizeof(cBuffer)))
    {
      // Scan cBuffer for the data you want
      // Homework assignment - you make it proper
      int ia=0, ib=0, ic=0, id=0, ie=0;
      if (4 == sscanf(cBuffer, "%d,%d,%d,%d,%d\n", ia, ib, ic, id, ie))
      {
        // You have the data, go populate one row in the Dialog
        // Then do the next 3 rows.
      }
    }
  }
<br />
}<br />

Gary

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.