ui->listView->model()->removeRows(0,ui->listView->model()->rowCount());
ui->listView->model()->removeRows是删除listview行内容,也就是清空,所选定行范围。
ui->listView->model()->rowCount()是查询list所显示的行数。

相关文章:

  • 2022-01-11
  • 2021-06-06
  • 2022-12-23
  • 2022-12-23
  • 2022-01-30
  • 2022-12-23
  • 2022-01-07
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-24
  • 2021-08-23
相关资源
相似解决方案