You are not logged in.

Dear visitor, welcome to If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.


Thursday, August 23rd 2012, 5:22pm

Default searching for QTableView


I have a QSqlTableModel displayed in a QTableView. I have the Edittriggers set to AnyKeyPressed but that only seems to work for characters and numbers. When a cell is selected and then I click SHIFT+N or any character it just searches that column for the 1st (from the top) cell with that character in it. Is there a way to disable this? I tried setting the edit trigger to AllEditTriggers which works for existing records but when I add a new record the 1st cell is selected and the same thing happens when SHIFT+char is pressed also I don't really want to use AllEditTriggers if possible.


Thursday, August 23rd 2012, 8:47pm

Solved this by just using MyTableView->edit(index) when I add a new record.