PDA

View Full Version : Read TXT file with QFile



puneet
8th April 2014, 07:06
Hi
Want to read the txt file with the help of QFile and when find the desired string(value) then return that.
There is a txt file with following format::
12asd = 12asd
34fgh = 34fgh
98nbv = 98nbv

wysota
8th April 2014, 08:03
Ok, and what is the question?

puneet
8th April 2014, 13:14
How to read the txt file with the help of Qfile.......

wysota
8th April 2014, 13:17
Hmm... most probably using QFile's "read" method.

anda_skoa
8th April 2014, 13:34
Or, even more conventient, using QTextStream on the file.

Cheers,
_