Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
QChartView update problem
o.semmler last edited by
I'm trying to connect QAbstractItemModel to QChartView.
I used the official example: https://doc.qt.io/qt-5/qtcharts-modeldata-example.html
The problem is that the chart does not update when adding a new row to the model.
I have tried different ways but without success.
Can you please advise on how to do this?
I found a similar problem here on the forum but nobody solved it:
Can you show how you are adding data to the model ?
Also, what version of Qt are you using ?
On what platform ?
MrShawn last edited by
Is it that the chart doesn't update or are your not adjusting your axis to have a range where the new data falls into?
Creating the default axis will provide a range to the axis that fits the data. However the axis range will not change, so if your new data is outside of that range it will appear to not be updating.