Results 1 to 5 of 5

Thread: QtWebView

  1. #1
    Join Date
    Sep 2010
    Posts
    9
    Qt products
    Qt4
    Platforms
    Windows

    Default QtWebView

    hi everyone

    I am a beginner to Qt,i am using QWebView to build small application in which ,from the client side i request for the Html page to the server,i am able to display the requested HTML page in the client side..but i am not able to navigate through any of the hyperlinks.Here is My code


    QwebView *WebView = new QwebView();
    WebView->load(QUrl("http://servername/XYZ.html"));
    WebView->show();
    However i am able load to XYZ.html successfully.but when i click the hyperlinks in XYZ.html,i am not able to see anything .

    connect(WebView,SIGNAL(linkClicked(const QUrl&),this,LinkChanged(const QUrl&)));

    and my slot looks like this
    void LinkChanged(const QUrl& link)
    {
    WebView->load(QUrl(link));
    WebView->show();

    }

    i have connect the linkclicked signal to the LinkChanged slot..i am getting the control to the slotalso.but QUrl parameter what i am passing is not getting the valid Url name.please suggest me if i have done something wrong in the code.

    please help in this regards

    Thanks
    santhosh Patil

  2. #2
    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: QtWebView

    Is your slot a stand-alone function or a method of some class?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  3. #3
    Join Date
    Sep 2010
    Posts
    9
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: QtWebView

    Its a method of a class

  4. #4
    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: QtWebView

    Is it executed at all? Basically you shouldn't need this slot at all. Try removing the connection and see if it helps.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


  5. #5
    Join Date
    Sep 2010
    Posts
    9
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: QtWebView

    Hi

    I tried by removing the slot ..its not working

Similar Threads

  1. Video in QtWebView
    By iUser59 in forum Qt Programming
    Replies: 0
    Last Post: 9th June 2009, 15:03

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.