I want to read a txt file, but I want to read word by word. So can you please show what function would be best to read word by word from the txt file Thanks.
with your code it seems to me that you want to open a file readonly, but with CFile::modeCreate you truncate the file to 0 bytes (equals empty the file).
You could use the TextReader and the ReadLine method to read a line. For each line read you can split it on the space character to get an array of words.
Want to read a txt file
Eric Tsai
shawncm217
OlivierJ
PatrickGreen
Would you mind sharing the assertion message
CalgaryDataGirl
JohnRM2