Results 1 to 6 of 6

Thread: Help with Qhttp and Proxy

  1. #1
    Join Date
    May 2007
    Posts
    6
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Red face Help with Qhttp and Proxy

    Hello this is my first post and perhaps there is not enough information or something wrong. First Hi!!! to all of you!!!!

    I am using QT HTTP example http://doc.trolltech.com/4.0/network-http.html (QT 4.2.2) for test because I need to make something similar in my project but I always received connection refuse when it start to transfer the file. Here are the degut output:
    ERROR: httpRequestStarted!
    ERROR: httpRequestFinished!
    ERROR: httpRequestStarted!
    The thread 'Win32 Thread' (0x1550) has exited with code 0 (0x0).
    ERROR: httpRequestFinished!
    ERROR Descriptor: Connection refused,

    But if I add to the example
    m_phttp->setProxy( "x.x.x.x", 8080); it works.
    I get it from my PC from registry under HKEY_CURRENT_USER\Software\Microsoft\Windows\Curre ntVersion\Internet Settings but how I can know that this value is needed? And how I can get it from whatever user because I needed that my SW be used in different user PC with different settings in their PC?
    Thanks a lot
    Katukina

  2. #2
    Join Date
    May 2007
    Posts
    6
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Help with Qhttp and Proxy

    Please can someone help me?

  3. #3
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Help with Qhttp and Proxy

    You can use QSettings to look this value up in the registry.

  4. The following user says thank you to wysota for this useful post:

    Katuakina (14th May 2007)

  5. #4
    Join Date
    May 2007
    Posts
    6
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Help with Qhttp and Proxy

    Hello
    Thanks for your reply but my question is When I need to look for that value in the registry? Always and if it has value uses SetProxy or when I have to uses Setproxy? Is not other way to know if proxy are needed?
    Br katukina

  6. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Help with Qhttp and Proxy

    The value you mention is a system value thus you have to query your system for it if you want to be aware of it. This means you have to use system calls to do that. In theory you could use QNetworkProxy but I never used that class and have no way of testing it in my environment as I don't use such proxies.

  7. #6
    Join Date
    May 2007
    Posts
    6
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Lightbulb Re: Help with Qhttp and Proxy

    Ok I will try both of them. Uses system calls and to study the QNetworkProxy class.
    Thanks Katya

Similar Threads

  1. QHTTP Status code
    By whoops.slo in forum Qt Programming
    Replies: 1
    Last Post: 28th November 2006, 09:18

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.