Hi,
In my Dialogclass I open a file
ui->FileEdit->setText(filepath);
ui->UpdateProgressBar->setRange(0,(file.size()-firstlineArray.size()));
firstlineArray.chop(1);
devicetypeFromFile = firstlineArray.toInt();
enableUpdateButton(true);
}
if(file.open(QIODevice::ReadOnly | QIODevice::Text)){
ui->FileEdit->setText(filepath);
QByteArray firstlineArray = file.readLine();
ui->UpdateProgressBar->setRange(0,(file.size()-firstlineArray.size()));
firstlineArray.chop(1);
devicetypeFromFile = firstlineArray.toInt();
enableUpdateButton(true);
}
To copy to clipboard, switch view to plain text mode
Now I want to have access to this file in my WorkerThread Class, because I need to read some lines from this file (it's a file with many hex-lines). The Dialog starts with a click on a Button the WorkerThread.
What is the best way to get the file to my Worker Thread?
Bookmarks