Hi!
I’d like to download a file, so that when download is started, it does not does not execute next command until file is downloaded.
An example of what I want:
QNetworkAccessManager nam;
QNetworkReply *r = nam.get(QNetworkRequest(QUrl("http://URL")));
QByteArray data = r.readAll(); // Everything already downloaded, even if file is several GB in size
I want my app to download a file, save it, and then exit. Nothing more. It’ll be started with QProcess, so there will be no GUI and no Qt event loop.
Regards,
Jake
↧