LogicStuff
LogicStuff

Reputation: 19617

Qt 5.4 with Visual Studio 2013 - QtCored.dll missing

Each time I reopen my solution in Visual Studio 2013 ultimate and start debugging, I get:

The program can't start because Qt5Cored.dll is missing from your computer. Try reinstalling the program to fix this program.

Rebuild Build->Project Only->Link Only solves the problem. I have 3 non-Qt projects in my solution, statically linked with the 4th Qt Application project. I'm using msvc2013_opengl x86 build. Have any of you experienced this before? Should you need more information, please ask.

Thank you in advance.

Upvotes: 3

Views: 4993

Answers (3)

Bim
Bim

Reputation: 1068

dudekings solution works, but this works for me too (tm) and might be slightly better:

PATH=$(QTDIR)\bin;$(Path)

because afaik it uses the VS environment variables you can set in property sheets etc. Note that it's not PATH, but Path...
You might also need the Qt platform plugins (aka qwindows.dll). For that also add the line:

QT_QPA_PLATFORM_PLUGIN_PATH=$(QTDIR)\plugins\platforms

Note that the variable QTDIR is set by the VS Qt-Addin, so make sure you have that installed and your project properly set up to be a Qt project (as-in managed by the Addin)! Otherwise it properly won't work.

Upvotes: 1

dudeking
dudeking

Reputation: 774

use

PATH=%QTDIR%\bin;%PATH%; 

following wont work

PATH=$(QTDIR)\bin;$(PATH); 

Upvotes: 7

Lahiru Chandima
Lahiru Chandima

Reputation: 24128

Not sure how rebuilding the project solves the issue. But following steps should fix it correctly.

Make sure QTDIR environment variable correctly points to your Qt directory.

Right click on executable project and select Properties.

Set Configuration to All Configurations

In Configuration Properties -> Debugging, set Environment to following

PATH=$(QTDIR)\bin;$(PATH);

Upvotes: 3

Related Questions