Solved Problems when i launch Qt executable from folder
-
Hey guys,
I have a little problem when i try to lunch my Qt application from folder and not from Qt IDE. If I launch the application from IDE the interface is ok (all widgets at their place) but after i copy all the needed Qt *.dll in the release folder the application run but pop up an empty window.
Has somebody any idea about how can i fix this problem and why is happening this?
Thank you :) -
@Adrian.Aioanei
What exactly do you mean withafter i copy all the needed Qt *.dll in the release folder
If you just double clicked your exe and searched and copied the dll's that poped up as missing, than you defenitly miss some files :)
Take a look here last entry
Platform-Specific Notes
is what you should check, depending on your platform, you'll find tools/guidlines how to deploy your application. -
Hey @J-Hilk
Your link doesn't work.:D
What i have done is to copy from Qt bin folder the dll that my application need (QtCore, QtGui, etc). -
@Adrian.Aioanei fixed the link,
yeah, that won't be enough follow the steps and post here if it doesn't work, or you need help.
-
Probably , you might be missed soem additional lbs. Use Dependency Walker .
check these Qt deploy tools on windows and http://doc.qt.io/qt-5/deployment.html -
@Adrian.Aioanei You also should check whether you copied all needed plug-ins
-
-
I have try and also doesn't work.
Can have a connection with the path to the build directory?
I have change that path from Qt and now i receive a warning and say "The build directory needs to be at the same level as the source directory". -
@Adrian.Aioanei Build directory? Why? You want to deploy your app, right? Check http://doc.qt.io/qt-5/windows-deployment.html
-
Yes, that's what i have done but still doesn't work. Every time when i launch my application popup a little window witch doesn't have any connection with my application. Here is what i get.
This is not how looks my application when i lunch from Qt. It has some buttons, labels and so on. -
@Adrian.Aioanei Set QT_DEBUG_PLUGINS to != 0 before starting your app in cmd and see whether any plug-ins are missing or failed to load. See http://doc.qt.io/qt-5/debug.html
-
I will try and also i will try on a new machine to see if the result is the same.
I will came back with results.
Thanks :) -
I have try on a new workstation and i have rebuild the project but the result is the same. I have made deploy using windeployqt following this video link. I have study the executable with dependency walker show me some missing dll. I was thinking the dll problem is solved by windeployqt . Here is a print
That dll name doesn't tell to much.
PS: I have also try to make an empty QML Quick 2 Application and make deploy. Also doesn't work...UPDATE : I have close the application and rebuild again and now say :
qrc:/test.qml:4:1: module "QtQuick.Controls" is not installed
qrc:/test.qml:5:1: module "QtQuick.Controls.Styles" is not installed
qrc:/test.qml:3:1: module "QtQuick.Window" is not installed
qrc:/test.qml:1:1: module "QtQuick" is not installed
qrc:/test.qml:4:1: module "QtQuick.Controls" is not installed
qrc:/test.qml:5:1: module "QtQuick.Controls.Styles" is not installed
qrc:/test.qml:3:1: module "QtQuick.Window" is not installed
qrc:/test.qml:1:1: module "QtQuick" is not installed
qrc:/test.qml:4:1: module "QtQuick.Controls" is not installed
qrc:/test.qml:5:1: module "QtQuick.Controls.Styles" is not installed
qrc:/test.qml:3:1: module "QtQuick.Window" is not installed
qrc:/test.qml:1:1: module "QtQuick" is not installed
qrc:/test.qml:4:1: module "QtQuick.Controls" is not installed
qrc:/test.qml:5:1: module "QtQuick.Controls.Styles" is not installed
qrc:/test.qml:3:1: module "QtQuick.Window" is not installedI have Qt 5.8.0
-
Hi,
You should use the
-qml
parameter of windeployqt so that it can go parse your application qml files and deploy what's needed to support them. -
Yes @SGaist , that was the problem.
The above error appears in qt creator when i have created the new project and i don't understand why.
I just made a new project and i have copy all the file from the old one to the new one and show this error when i try to launch.
The old project works fine without any error.
Do i need to setup something from project configuration ? -
Do you mean from Qt Creator ?
-
Yes. I don't remember if i have setup something to my previews project, but the think is the second doesn't work.
-
Which version of Qt are you using ?
Did you setup the .pro file the same way ?
-
Yes, i have
Sorry for my delay. :D
There was the problem. Now works fine.
Thank you very much all. :D
PS: I don't know how to mark as solved this topic. -