QSqlTableModel saves resutls only when return is pressed & And auto sorting after the data is inserted



  • Hey,
    I have two questions

    1. I have a table and when a row is added the user double clicks on a column and inserts his/her data, now to go to the next column if the user presses 'TAB' key the cursor goes to the next tab but the data isn't saved, how can i fix this?
    2. now after the new row is inserted the the data needs to be sorted bt if the user opens the new table(the model and view are recreated) the data is sorted bt while editing or creating new entry it isn't how can i add this feature?

    I'm using QSqlTableModel and QTableview.
    thanks in advance :)


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.