This is the code that i do:
`void Tabella::on_pushButton_clicked()
{
int risultato;
risultato = ui->treeWidget->currentItem()->text(2);
ui->out_3->setText(QString::number(risultato));
}`
Are the any ways to assign the code into variable? Like that?
P.S I'm new in QT, i worked with c++ and java.