This surprises me, and I tend to think that either the code you posted is not 100% the same as you really use it, or, something else that you do.In my case it points to "abc.txt"
The stream is not 'pointing' to anything, it takes a reference to a QFile (actually a QIODevice) object.
This means, the stream doesn't know anything about the file name - it just streams to the device it has a reference to, and that device may have any filename what so ever - the QFile object is reposible for opening the physical file, not the stream.
Make sure you are not setting a different file name to an already open QFile object.





Reply With Quote
Bookmarks