Click here to Skip to main content
15,923,006 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerI was thinking... Pin
Roland_19805-Nov-03 10:59
Roland_19805-Nov-03 10:59 
GeneralRe: I was thinking... Pin
Joaquín M López Muñoz5-Nov-03 11:57
Joaquín M López Muñoz5-Nov-03 11:57 
GeneralMixing ideas 2gether... Pin
Roland_19805-Nov-03 13:03
Roland_19805-Nov-03 13:03 
GeneralRe: Mixing ideas 2gether... Pin
Garth J Lancaster5-Nov-03 15:15
professionalGarth J Lancaster5-Nov-03 15:15 
Generalincluding multiple headers Pin
wogerdoger5-Nov-03 8:40
wogerdoger5-Nov-03 8:40 
GeneralRe: including multiple headers Pin
Maximilien5-Nov-03 9:00
Maximilien5-Nov-03 9:00 
Generalreading text file in vc++ .net Pin
pnpfriend5-Nov-03 8:31
pnpfriend5-Nov-03 8:31 
GeneralRe: reading text file in vc++ .net Pin
Christian Graus5-Nov-03 8:37
protectorChristian Graus5-Nov-03 8:37 
fstream.h does not exist in VS.NET ? Good. it's not standard C++, and never was. Drop the .h from ALL your standard headers, in this case, include fstream, NOT fstream.h. You'll then find that everything is in the std namespace, so you'll need to either put

using std::ifstream

or use it like this:

std::fstream inputFile.....

Also, ios::in is the default mode for an ifstream, you don't need to put it ( and if you did, it will need std:: as well ). In the same line, getline also defaults to use \n ( and of course, you're not checking if the file is bigger than 1k ).


Christian

I have drunk the cool-aid and found it wan and bitter. - Chris Maunder
GeneralRe: reading text file in vc++ .net Pin
pnpfriend5-Nov-03 9:08
pnpfriend5-Nov-03 9:08 
GeneralRe: reading text file in vc++ .net Pin
Christian Graus5-Nov-03 9:11
protectorChristian Graus5-Nov-03 9:11 
GeneralRe: reading text file in vc++ .net Pin
pnpfriend5-Nov-03 9:13
pnpfriend5-Nov-03 9:13 
GeneralMSflexgrid limit Pin
act_x5-Nov-03 8:30
act_x5-Nov-03 8:30 
GeneralRe: MSflexgrid limit Pin
David Crow5-Nov-03 8:38
David Crow5-Nov-03 8:38 
Generalbitmap problem Pin
kendao5-Nov-03 8:28
kendao5-Nov-03 8:28 
GeneralRe: bitmap problem Pin
Christian Graus5-Nov-03 8:38
protectorChristian Graus5-Nov-03 8:38 
GeneralUpdating a window! Pin
Dracula50005-Nov-03 8:06
Dracula50005-Nov-03 8:06 
GeneralRe: Updating a window! Pin
Christian Graus5-Nov-03 8:41
protectorChristian Graus5-Nov-03 8:41 
GeneralRe: Updating a window! Pin
JDasari6-Nov-03 6:55
JDasari6-Nov-03 6:55 
GeneralIIS & Chunk Encoded Data Support Pin
lsacalvi5-Nov-03 6:13
lsacalvi5-Nov-03 6:13 
GeneralTerminal Server Install Mode Pin
Steve Thresher5-Nov-03 4:26
Steve Thresher5-Nov-03 4:26 
GeneralNetwork User Name on the Task Bar Pin
WinBond5-Nov-03 3:33
WinBond5-Nov-03 3:33 
GeneralRe: Network User Name on the Task Bar Pin
David Crow5-Nov-03 4:58
David Crow5-Nov-03 4:58 
GeneralRe: Network User Name on the Task Bar Pin
WinBond5-Nov-03 20:39
WinBond5-Nov-03 20:39 
GeneralRe: Network User Name on the Task Bar Pin
David Crow6-Nov-03 6:18
David Crow6-Nov-03 6:18 
GeneralRe: Network User Name on the Task Bar Pin
WinBond7-Nov-03 0:11
WinBond7-Nov-03 0:11 

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.