Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Update: Forum Guidelines & Code of Conduct


    Qt World Summit: Early-Bird Tickets

    QWebView problems with Qt 5.0.2 win 64bits under windows 7 [SOLVED]

    General and Desktop
    3
    8
    5365
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • I
      iqbal1980 last edited by

      If I run without a QWebView it runs fine when I add a QWebView to the mainwindow.ui I get couple of errors. I did add QT += webkit
      as I encountered a similar problem with 4.8 but the problem still persist.

      mainwindow.obj:-1: error: LNK2019: unresolved external symbol "__declspec(dllimport) public: __cdecl QWebView::QWebView(class QWidget *)" (_imp??0QWebView@@QEAA@PEAVQWidget@@@Z) referenced in function "public: void __cdecl Ui_MainWindow::setupUi(class QMainWindow *)" (?setupUi@Ui_MainWindow@@QEAAXPEAVQMainWindow@@@Z)

      mainwindow.obj:-1: error: LNK2019: unresolved external symbol "__declspec(dllimport) public: virtual __cdecl QWebView::~QWebView(void)" (_imp??1QWebView@@UEAA@XZ) referenced in function "public: virtual void * __cdecl QWebView::`scalar deleting destructor'(unsigned int)" (??_GQWebView@@UEAAPEAXI@Z)

      mainwindow.obj:-1: error: LNK2019: unresolved external symbol "__declspec(dllimport) public: void __cdecl QWebView::setUrl(class QUrl const &)" (_imp?setUrl@QWebView@@QEAAXAEBVQUrl@@@Z) referenced in function "public: void __cdecl Ui_MainWindow::setupUi(class QMainWindow *)" (?setupUi@Ui_MainWindow@@QEAAXPEAVQMainWindow@@@Z)

      mainwindow.obj:-1: error: LNK2001: unresolved external symbol "protected: virtual void __cdecl QWebView::changeEvent(class QEvent *)" (?changeEvent@QWebView@@MEAAXPEAVQEvent@@@Z)

      mainwindow.obj:-1: error: LNK2001: unresolved external symbol "protected: virtual void __cdecl QWebView::contextMenuEvent(class QContextMenuEvent *)" (?contextMenuEvent@QWebView@@MEAAXPEAVQContextMenuEvent@@@Z)

      mainwindow.obj:-1: error: LNK2001: unresolved external symbol "protected: virtual class QWebView * __cdecl QWebView::createWindow(enum QWebPage::WebWindowType)" (?createWindow@QWebView@@MEAAPEAV1@W4WebWindowType@QWebPage@@@Z)

      mainwindow.obj:-1: error: LNK2001: unresolved external symbol "protected: virtual void __cdecl QWebView::dragEnterEvent(class QDragEnterEvent *)" (?dragEnterEvent@QWebView@@MEAAXPEAVQDragEnterEvent@@@Z)

      And many other similar link errors

      ????

      Any help would be much apreciated.

      Thanks,

      1 Reply Last reply Reply Quote 0
      • I
        iqbal1980 last edited by

        If removed the win 64 version and installed the mingw47 version instead same problem but different error message

        1 Reply Last reply Reply Quote 0
        • raven-worx
          raven-worx Moderators last edited by

          Do the following in your PRO file:
          QT += webkit webkitwidgets

          --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
          If you have a question please use the forum so others can benefit from the solution in the future

          1 Reply Last reply Reply Quote 0
          • B
            b1gsnak3 last edited by

            Yes you need to add webkitwidgets module in your PRO file because from Qt 5.0 they reworked the modules so that QtWidgets and QtWebkitWidgets are separate modules from QtGui and QtWebkit

            1 Reply Last reply Reply Quote 0
            • I
              iqbal1980 last edited by

              Thank you that works :)

              1 Reply Last reply Reply Quote 0
              • B
                b1gsnak3 last edited by

                mark post as solved please :)

                1 Reply Last reply Reply Quote 0
                • I
                  iqbal1980 last edited by

                  Ok! how do I do that I'm new here.

                  1 Reply Last reply Reply Quote 0
                  • B
                    b1gsnak3 last edited by

                    Just edit your first post, and in the title section add [SOLVED]

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post