Documentation says it better than I could.
You can click on the hyperlinks to get directly to each explanation.
thines01
Postaholic
2,424 posts since Oct 2009
Reputation Points: 445
Solved Threads: 402
If you give it a maxlen value, that's all it will read.
If you set the parameter to 10, it will read 10 characters from the stream.
Since it sounds like the amount of data the user can type is of variable length and that you recognize the next comment by a special character, I suggest you readAll() and then parse the QString (if it's not too much data).
If the amount you're trying to read is too much, you would need to read() the data based on the amount you can process at any time and parse that data based on the location of the special character. Any incomplete comment records would need to be joined totether.
Is that what you meant?
thines01
Postaholic
2,424 posts since Oct 2009
Reputation Points: 445
Solved Threads: 402