Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
I want to count number of rows in a selected file. I also need to do it with QFile and QDir. Thanks for your help.
@eefesafak Assuming by "rows" you mean "lines". Open the file for text read, use QFile::readline() to read lines, count as you go?
QFile::readline()
why do something programatically that already exists in command line utils?
wc -l file
but I digres since these kind of questions often indicate a sub-optimal file IO paradigm like line based file records. Bleck!