codetoad.com
  ASP Shopping CartForum & BBS
  - all for $20 from CodeToad Plus!
  
  Home || ASP | ASP.Net | C++/C# | DHTML | HTML | Java | Javascript | Perl | VB | XML || CodeToad Plus! || Forums || RAM 
Search Site:
Search Forums:
  reading in from a text file  micky at 01:16 on Monday, September 17, 2007
 

hi
im a uni student and im having a whole lot of trouble reading in from a text file. i have recently completed an assignment where every word was only seperated by a single white space. i therefore was able to use getline(inputfile, idvalue, ' '); or getline(inputfile, score1, ' '); . this time they are seperated by many diffrent amounts of space. the file shown below is a sample of what i must read in. it represents a student id followed by 4 differed scores each student student has received. thank you to any one that can help


s9000002 9 7 10 135
s9000004 6 9 6 150
s7000001 10 10 10 175
s8000002 9 7 10 135
s8000004 6 9 6 150
s8000001 10 10 10 175
s7000002 9 7 10 135
s7000004 6 9 6 150
s9000001 10 10 10 175
s0000002 9 7 10 135
s0000004 6 9 6 150
s0000001 10 10 10 170


<Added>

s9000002 9 7 10 135
s9000004 6 9 6 150
s7000001 10 10 10 175
s8000002 9 7 10 135
s8000004 6 9 6 150
s8000001 10 10 10 175
s7000002 9 7 10 135
s7000004 6 9 6 150
s9000001 10 10 10 175
s0000002 9 7 10 135
s0000004 6 9 6 150
s0000001 10 10 10 170









CodeToad Experts

Can't find the answer?
Our Site experts are answering questions for free in the CodeToad forums
//








Recent Forum Threads
•  Job @ EarlySail
•  Job @ EarlySail (perl)
•  Security - Code verify
•  IPC problem
•  Re: import contacts of msn/yahoo
•  Cookies and Threads C++
•  right justify a background in a table?
•  Help with Loop (C++/MFC)
•  Help with Loop (C++/MFC)


Recent Articles
ASP GetTempName
Decode and Encode UTF-8
ASP GetFile
ASP FolderExists
ASP FileExists
ASP OpenTextFile
ASP FilesystemObject
ASP CreateFolder
ASP CreateTextFile
Javascript Get Selected Text


© Copyright codetoad.com 2001-2007