Qt World Summit: Register Today!

module "QtQuick.Controls" is not installed (static Qt 64bit Win10)

  • Hello all,

    I have built Qt 5.5.1 statically for Windows10 (using MinGW) and I'm trying to build a simple Qml app using this 64 bit kit.
    here is the content of main.cpp:

    QGuiApplication app(argc, argv);
    TestApp testApp;
    QQmlApplicationEngine engine;
    QQmlContext* context = engine.rootContext();
    engine.addImportPath( QStringLiteral("/qml") );
    engine.addImportPath( QStringLiteral("/qml/QtQuick") );
    engine.addImportPath( QStringLiteral("/qml/QtQuick/Controls") );

    Here the content of main.qml

    import QtQuick 2.5
    import QtQuick.Window 2.2
    import QtQuick.Controls 1.1
    Window {
        visible: true
        width: Screen.width
        height: Screen.height
            Button {
                id: runButton
                anchors.verticalCenter: parent.verticalCenter
                text: "Click Me!"
                width: implicitWidth
                height: implicitHeight
                onClicked: {

    The exe gets compiled just fine but when I launch it I get the runtime error
    "module "QtQuick.Controls" is not installed"

    I've been searching on the forums and googled a lot but I didn't find a solution.
    Do you guys have some idea

    Thanks in advance!

  • Have you deployed the app? Used windeployqt? Anyways, the Quick Controls QML code must also be copied to your local app directory, do you have them in the locations which you have given to engine.addImportPath? They can be copied from the binary Qt distribution, this is what windeployqt does. I suppose you have checked that you have actually compiled Quick Controls c++ code into you static build beforehand (I don't know if it's possible to leave them out, I'm not familiar with static builds).

  • Hi Eeli,

    Yes, I have used windeployqt_64 but it does not copy anything, I suppose because Qt is statically linked.

    here is what winseployqt prints after it has finished:

    Warnings while parsing QML type information of C:/Qt/qt-everywhere-enterprise-src-5.5.1/qtbase/qml/QtCharts:
    C:\Qt\qt-everywhere-enterprise-src-5.5.1\qtbase\qml\QtCharts\plugins.qmltypes:1:24: Reading only version 1.1 parts.
    C:\Qt\qt-everywhere-enterprise-src-5.5.1\qtbase\qml\QtCharts\plugins.qmltypes:10:5: Expected only Component and ModuleApi object definitions.

    Then I copied manually the whole qml folder to the folder where my exe is. So it should be able to find it.

    Qtquickcontrols should be compiled and linked correctly, otherwise I would have had linker problems, wouldn't I ?

Log in to reply