Results 1 to 5 of 5

Thread: things on QSqlRelationalTableModel , QDataWidgetMapper and QTableView

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #4
    Join Date
    Jan 2006
    Location
    Belgium
    Posts
    1,938
    Thanked 268 Times in 268 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Wiki edits
    20

    Default Re: things on QSqlRelationalTableModel , QDataWidgetMapper and QTableView

    Quote Originally Posted by xiongxiongchuan View Post
    Qt Code:
    1. SIGNAL(setCurrentModelIndex())
    To copy to clipboard, switch view to plain text mode 
    That's not a signal.

    Qt Code:
    1. SLOT(currentChanged())
    To copy to clipboard, switch view to plain text mode 
    That's not a slot.

    To quote the documentation:
    The following example illustrates how to update all widgets with new data whenever the selection of a QTableView named myTableView changes:
    Qt Code:
    1.  
    2. connect(myTableView->selectionModel(), SIGNAL(currentRowChanged(QModelIndex,QModelIndex)),
    3. mapper, SLOT(setCurrentModelIndex(QModelIndex)));
    To copy to clipboard, switch view to plain text mode 

  2. The following user says thank you to tbscope for this useful post:

    xiongxiongchuan (13th June 2010)

Similar Threads

  1. Replies: 2
    Last Post: 29th December 2012, 14:14
  2. QSqlRelationalTableModel QDataWidgetMapper
    By kawoN in forum General Programming
    Replies: 4
    Last Post: 26th May 2010, 09:30
  3. Replies: 1
    Last Post: 18th March 2009, 21:26
  4. QDataWidgetMapper to synchronize widgets with QTableView
    By ehamberg in forum Qt Programming
    Replies: 4
    Last Post: 21st February 2008, 20:46
  5. QDataWidgetMapper and QSqlRelationalTableModel problem
    By larry104 in forum Qt Programming
    Replies: 1
    Last Post: 14th November 2007, 15:46

Tags for this Thread

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.