View Single Post
  #1 (permalink)  
Old October 15th, 2003, 05:45 PM
Omega_st1 Omega_st1 is offline
Registered User
 
Join Date: Oct 2003
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default reading a row of characters from an input file

Ok, I am trying to read a row of characters which should be a single string from an input file. the input file is a plain text .dat file that has each piece of data on a separate line. In my program, I have a variable which reads the character data with a 'char' data type.

problem is, it only reads the first character and that's it.
Because I'm new to C++ i'm not sure what data type i can use to have it read the entire line of characters as one. Please help!!

Reply With Quote