Results 1 to 3 of 3

Thread: QIODEvice

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Posts
    976
    Thanks
    53
    Qt products
    Qt3
    Platforms
    Windows

    Default QIODEvice

    hi, i'm trying to use qiodevice to do this....
    Qt Code:
    1. QFile f(file);
    2. bool b = f.open(IO_ReadOnly);
    3. bool read_result = Read(f);
    To copy to clipboard, switch view to plain text mode 
    Qt Code:
    1. bool Read(QIODevice& io) {
    2. QString s = doc.toString(); // this cause runtime error
    3. // cout << " s " << s << endl;
    4. if ( !doc.setContent( &io ) ) return false; //here program exit
    To copy to clipboard, switch view to plain text mode 
    Why this fragment has that behavoiur? (which cause) thanks
    Last edited by mickey; 5th July 2006 at 17:54.
    Regards

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.