PDA

View Full Version : Visual Studio 2010 and QWebView



qt_developer
11th July 2014, 10:10
Hi,

I'm trying to compile a project in Visual Studio 2010 that uses the QWebView class. When I try to compile, I get the next error: cannot open source file "QWebView".

I'm using Qt 4.8.0.

What's wrong?

Regards.

ChrisW67
11th July 2014, 10:31
Your PRO file is probably missing:


QT += webkit


I do not know how you arrange that if you are using the Visual Studio plugin.

qt_developer
11th July 2014, 10:35
I'm using Visual Studio, I don't have .pro file.

I've solved the issue adding C:\Qt\4.8.0\include\QtWebKit in 'Additional Include Directories' of C/C++->General and QtWebKit4.lib in 'Additional Dependencies' of Linker->General in the project configuration properties.

Lesiok
11th July 2014, 10:50
Install Visual Studio Add-in (http://download.qt-project.org/official_releases/vsaddin/qt-vs-addin-1.1.11-opensource.exe) and then you will have the tools to properly define Qt projects.