Results 1 to 3 of 3

Thread: link the content og a QComboBox to a databse table

  1. #1
    Join Date
    Sep 2008
    Location
    Portugal
    Posts
    171
    Thanks
    57
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default link the content og a QComboBox to a databse table

    Hi,
    Is the an "automated" way to load items from a database into a QComboBox.
    Not looking for a line by line read/write approach.
    Thanks

  2. #2
    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: link the content og a QComboBox to a databse table

    Yes, use a data widget mapper and the correct model.
    http://doc.qt.nokia.com/4.6/qdatawidgetmapper.html

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

    graciano (16th June 2010)

  4. #3
    Join Date
    Sep 2008
    Location
    Portugal
    Posts
    171
    Thanks
    57
    Thanked 4 Times in 4 Posts
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default Re: link the content og a QComboBox to a databse table

    Thanks ... that is exactly what i was looking for.

Similar Threads

  1. Need info about databse in qt4
    By newtowindows in forum Installation and Deployment
    Replies: 1
    Last Post: 28th October 2009, 15:42
  2. Stored Procedure in Firebird databse (IBase)
    By Specialized1 in forum Qt Programming
    Replies: 2
    Last Post: 15th September 2009, 10:47
  3. get mysql table into QComboBox
    By eleanor in forum Qt Programming
    Replies: 17
    Last Post: 10th October 2007, 16:35
  4. Replies: 9
    Last Post: 21st June 2007, 11:27
  5. sort content in the Qcombobox
    By Levon Nikoghosyan in forum Qt Programming
    Replies: 3
    Last Post: 25th October 2006, 21: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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.