Skip to content
  • 0 Votes
    15 Posts
    2k Views
    aha_1980A

    Hi @UnitScan,

    so please mark this topic as SOLVED too. Thanks!

  • 0 Votes
    6 Posts
    2k Views
    E

    @JNBarchan QStandardItemModel uses QVariant as data. You can set and get any QVariant compatible data. There's no reason to have error handling because the class isn't meant for error prone data. See QStandardItem and QVariant for details. QSqlTableModel.lastError is specific to SQL.

    If you want to, you can implement your own runtime error handling in your model. QStandardItemModel is mostly meant for simple cases, but you can subclass it as the docs say: "Reimplement data() and setData() if you want to perform custom handling of data queries and/or control how an item's data is represented." Just add your own error handling mechanism. Or inherit from QAbstractItemModel if performance and low-level details are important. QSqlTableModel does that, adding SQL specific things, one of which is SQL error handling.

  • 0 Votes
    11 Posts
    6k Views
    ivanperinoI

    @kuzulis I used putty just to send data to my app. As you suggest, putty doesn´t detect parity errors.