views:

363

answers:

2

Hey everyone,

I'm facing some trouble when using the class QNetworkAccessManager.

I use it to download a simple file from an url like "http://www.foo.com/bar/foobar.txt".

When I start a download I use :

m_pNetworkReply = m_pNetworkAccessManager->get(QNetworkRequest(m_CurrentFileToDownload));

Then I connect a few slots to receive, for example, errors during the process of downloading the file.

My problem is, if the computer is using a proxy, how do I manage to know it ? I've seen the class QNetworkProxy but how do I initialise it ?

Is there a way to match the settings of the default browser ? Do I have to let the user configure himself the proxy ?

I hope my question is clear...

Thanks in advance for your help and advices !

+2  A: 

Take a look into these functions:

guruz
Yes, I've found them too... And you're right, it seems they will help me !Thanks for your answer !
Andy M
A: 

can any one provide me the sample for using systemProxyForQuery and setProxyFactory

jay