Advertisement

Having an infile.getline problem!

Started by November 06, 2000 01:37 PM
0 comments, last by antness 24 years, 2 months ago
class item { public: apstring name; apstring shortName; apstring lookDesc; int type; void infileData(ifstream&infile) { infile.getline(buff, 30); name = buff; infile.getline(buff, 30); shortName = buff; infile.getline(buff, 80); lookDesc = buff; } private: char buff[80]; }; The problem is that only the first getline is actually doing anything!!!!!!! Help! Also adding ''\n'' as a parameter doesn''t help
problem fixed. i just added another getline.infile() to the top.

This topic is closed to new replies.

Advertisement