What is the best way to show in progress bar the progress of file upload?
-
It depends on the classes you use for uploading your data. You might want to look into the "QNetworkReply::uploadProgress() ":http://doc.qt.nokia.com/4.7/qnetworkreply.html#uploadProgress signal and connect it to the progressbar.
-
If you use a file you might want to use this:
sendProgress->setValue( (fileToSend->pos() * 100) / fileToSend->size());
The pos() functions comes from the QIODevice class, but it is inherited by QFile.