PDA

View Full Version : Removing all Items from QListView



subrat17june
6th June 2013, 07:44
Hi all,
How can i delete all rows/items from a QListview.
I am using QStandardItem to insert rows into a QListview.

At a point i want to remove all the elements that are present in the QListview.

can i get some code help on how to use QModelIndex or some other means to remove all elements from the QListView?

Thank You.

anda_skoa
6th June 2013, 12:07
clear the model. The view only displays the model's content.

Cheer,
_