Results 1 to 3 of 3

Thread: QFileDialog problem

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Aug 2008
    Location
    Ukraine, Krivoy Rog
    Posts
    1,963
    Thanked 370 Times in 336 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: QFileDialog problem

    where is writeToFile located? QTableWidget doesn't have such method.
    Qt Assistant -- rocks!
    please, use tags [CODE] & [/CODE].

  2. #2
    Join Date
    Feb 2008
    Posts
    50
    Thanks
    1
    Thanked 2 Times in 2 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QFileDialog problem

    He probably missed to implement the writeToFile function from AddressWidget example

    Qt Code:
    1. void AddressWidget::writeToFile(QString fileName)
    2. {
    3. QFile file(fileName);
    4.  
    5. if (!file.open(QIODevice::WriteOnly)) {
    6. QMessageBox::information(this, tr("Unable to open file"), file.errorString());
    7. return;
    8. }
    9.  
    10. QList< QPair<QString, QString> > pairs = table->getList();
    11. QDataStream out(&file);
    12. out << pairs;
    13. }
    To copy to clipboard, switch view to plain text mode 

Similar Threads

  1. Weird problem: multithread QT app kills my linux
    By Ishark in forum Qt Programming
    Replies: 2
    Last Post: 8th August 2008, 09:12
  2. QFileDialog in Qt designer
    By tpf80 in forum Qt Tools
    Replies: 1
    Last Post: 17th May 2007, 00:41
  3. Problem in the QFileDialog
    By joseph in forum Qt Programming
    Replies: 11
    Last Post: 7th December 2006, 09:56
  4. Qfiledialog Problem - (Beginner)
    By kingslee in forum Qt Tools
    Replies: 3
    Last Post: 11th October 2006, 23:00
  5. Replies: 16
    Last Post: 7th March 2006, 15:57

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.