64,635
社区成员
发帖
与我相关
我的任务
分享
QList<QTableWidgetSelectionRange>ranges = ui->tableWidget->selectedRanges();
int count=ranges.count();
for(int i=0;i<count;i++)
{
int topRow=ranges.at(i).topRow();
int bottomRow=ranges.at(i).bottomRow();
for(int j=topRow;j<=bottomRow;j++)
{
qDebug()<<"selectRow"<<j;
}
}