Hi,
I had this working yesterday, my table was being updated / refreshed by doing the following :
beginInsertRows(index, 1, nAmount);
if( pData )
{
for( int i = 0; i < nAmount; i++ )
{
m_Data.append(pData[i].strId);
m_Data.append(pData[i].strTime);
m_Data.append(pData[i].strData);
strCount.sprintf( "%i", nCount );
m_Data.append(strCount);
nCount++;
}
}
endInsertRows();
QModelIndex index;
beginInsertRows(index, 1, nAmount);
if( pData )
{
for( int i = 0; i < nAmount; i++ )
{
m_Data.append(pData[i].strId);
m_Data.append(pData[i].strTime);
m_Data.append(pData[i].strData);
QString strCount;
strCount.sprintf( "%i", nCount );
m_Data.append(strCount);
nCount++;
}
}
endInsertRows();
To copy to clipboard, switch view to plain text mode
Now, the table is only refreshed when it scrolls or I click on it?
Don't know what is wrong?!
Any help is appreciated.
Steve
Bookmarks