[Qt-interest] Removing the QListWidget Item

Yuvaraj R yuvaraj at ongobiz.com
Mon Jul 27 14:45:29 CEST 2009


Hi All


  I ma used the takeItem instead of removeItem widget.. It is working..


Thanks

Yuvaraj R

On Mon, Jul 27, 2009 at 5:39 PM, Yuvaraj R <yuvaraj at ongobiz.com> wrote:

> Hi All
>
>  I am facing problem with removing item from QListWidget.
>
> I am trying with
>
> for(int i=0; i< m_ui->listWidget->count();i++)
>
> {
>
> qDebug() << "dropping ";
>
> if(user == m_ui->listWidget->item(i)->text())
>
> {
>
> QListWidgetItem *item = m_ui->listWidget->item(i);
>
> qDebug() << item->text();
>
> qDebug() << "drop";
>
> m_ui->listWidget->removeItemWidget(item);
>
> qDebug() << "Removed";
>
> return;
>
> }
>
>  i don't get any errors..
>
> Please help me to solve this issue
>
>
> Thanks
>
>
> Yuvaraj R
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090727/2c4ae218/attachment.html 


More information about the Qt-interest-old mailing list