Skip to content

Instantly share code, notes, and snippets.

@jamalkhan2k6
Created October 22, 2013 08:32
Show Gist options
  • Save jamalkhan2k6/7097136 to your computer and use it in GitHub Desktop.
Save jamalkhan2k6/7097136 to your computer and use it in GitHub Desktop.
QTableWidget Manipulate
void MainWindow::attendance_table(){
//QTableWidgetItem *itm = new QTableWidgetItem();
ui->att_table->setColumnCount(15);
QStringList label;
label <<tr("ID") << tr("Name") << tr("1") << tr("2") << tr("3") << tr("4") << tr("5") << tr("6") << tr("7") << tr("8") << tr("9") << tr("10") << tr("11") << tr("12") << tr("13") ;
ui->att_table->setHorizontalHeaderLabels(label);
ui->att_table->verticalHeader()->hide();
ui->att_table->setShowGrid(false);
// QTableWidgetItem *itm = new QTableWidgetItem(tr("Name"));
//ui->att_table->setItem(0,0,itm);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment