Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. .exe file is not opening
Forum Updated to NodeBB v4.3 + New Features

.exe file is not opening

Scheduled Pinned Locked Moved Solved Installation and Deployment
28 Posts 6 Posters 4.7k Views 1 Watching
  • 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.
  • V Vijaykarthikeyan

    @jsulm same issue.

    after running the command in corresponding directory like: windeployqt.exe --qmldir <path/to/qml library> <file_name.exe> ..it is scanned and updated allthe required libraries Screenshot 2023-09-04 145459.png

    when running that project's .exe file.,it is showing showMaximized,widgets.dll,webengine.dll,qt5core.dll,webenignecore.dll is not located in dllScreenshot 2023-09-04 145222.png

    all the requires libraries are updated but it shows error like this:Screenshot 2023-09-04 145715.png

    Is that any wrong with my command?

    johngodJ Offline
    johngodJ Offline
    johngod
    wrote on last edited by
    #18

    @Vijaykarthikeyan said in .exe file is not opening:

    windeployqt.exe --qmldir <path/to/qml library> <file_name.exe> --compiler-runtime

    If you use Qt6 you need to use windeployqt6.exe instead of windeployqt.exe and you need to add --compiler-runtime to copy the missing compiler files

    To sum it all up, I usually create a folder were I copy only the executable file, cd in to that folder and run the windeployqt6 from there:

    cd D:\qtprojets\MyAppDeployFolder

    C:\QtOpensourse\6.5.0\mingw_64\bin\windeployqt6.exe --qmldir D:\qtprojets\MyApp D:\qtprojets\MyAppDeployFolder\MyApp.exe --compiler-runtime

    If you have several Qt versions, you should use the same windeployqt6.exe version of the compiled exe file

    V 1 Reply Last reply
    3
    • johngodJ johngod

      @Vijaykarthikeyan said in .exe file is not opening:

      windeployqt.exe --qmldir <path/to/qml library> <file_name.exe> --compiler-runtime

      If you use Qt6 you need to use windeployqt6.exe instead of windeployqt.exe and you need to add --compiler-runtime to copy the missing compiler files

      To sum it all up, I usually create a folder were I copy only the executable file, cd in to that folder and run the windeployqt6 from there:

      cd D:\qtprojets\MyAppDeployFolder

      C:\QtOpensourse\6.5.0\mingw_64\bin\windeployqt6.exe --qmldir D:\qtprojets\MyApp D:\qtprojets\MyAppDeployFolder\MyApp.exe --compiler-runtime

      If you have several Qt versions, you should use the same windeployqt6.exe version of the compiled exe file

      V Offline
      V Offline
      Vijaykarthikeyan
      wrote on last edited by
      #19

      @johngod I'm using 5.15.2

      johngodJ 1 Reply Last reply
      0
      • V Vijaykarthikeyan

        @johngod I'm using 5.15.2

        johngodJ Offline
        johngodJ Offline
        johngod
        wrote on last edited by
        #20

        @Vijaykarthikeyan Did it work ? If so, please mark the this as solved.

        V 2 Replies Last reply
        1
        • johngodJ johngod

          @Vijaykarthikeyan Did it work ? If so, please mark the this as solved.

          V Offline
          V Offline
          Vijaykarthikeyan
          wrote on last edited by
          #21

          @johngod I'm using 5.15.2 version. I've added --no-compiler-runtime at the end..

          My command is like this one: C:\Qt\5.15.2\msvc2019_64\bin>windeployqt.exe --qmldir C:\Users\hp\build-incline2-Desktop_Qt_5_15_2_MSVC2019_64bit-Release\exe --no-compiler-runtime

          the bit versions are correct and correct directory..

          but it is not importing any libraries in that exe folder..still get 4 error messages..Please help me to sort it out.

          jsulmJ 1 Reply Last reply
          0
          • V Vijaykarthikeyan

            @johngod I'm using 5.15.2 version. I've added --no-compiler-runtime at the end..

            My command is like this one: C:\Qt\5.15.2\msvc2019_64\bin>windeployqt.exe --qmldir C:\Users\hp\build-incline2-Desktop_Qt_5_15_2_MSVC2019_64bit-Release\exe --no-compiler-runtime

            the bit versions are correct and correct directory..

            but it is not importing any libraries in that exe folder..still get 4 error messages..Please help me to sort it out.

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by
            #22

            @Vijaykarthikeyan said in .exe file is not opening:

            --qmldir

            This should point to your QML files in the project folder, not in build folder as far as I know. And you're also missing path to the exe file when calling windeployqt.exe.

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            V 2 Replies Last reply
            2
            • jsulmJ jsulm

              @Vijaykarthikeyan said in .exe file is not opening:

              --qmldir

              This should point to your QML files in the project folder, not in build folder as far as I know. And you're also missing path to the exe file when calling windeployqt.exe.

              V Offline
              V Offline
              Vijaykarthikeyan
              wrote on last edited by
              #23

              @jsulm Thank you so much.. Your guidance solved my long term problem. I'm trying to search the solution for last two months. At last, that .exe file s running.. Thank you once again.. thank you too @johngod .. I owe you both

              1 Reply Last reply
              1
              • V Vijaykarthikeyan has marked this topic as solved on
              • johngodJ johngod

                @Vijaykarthikeyan Did it work ? If so, please mark the this as solved.

                V Offline
                V Offline
                Vijaykarthikeyan
                wrote on last edited by
                #24

                @johngod Yes,it is working..you have solved my 2 months problem..thank you soooo much

                1 Reply Last reply
                0
                • jsulmJ jsulm

                  @Vijaykarthikeyan said in .exe file is not opening:

                  --qmldir

                  This should point to your QML files in the project folder, not in build folder as far as I know. And you're also missing path to the exe file when calling windeployqt.exe.

                  V Offline
                  V Offline
                  Vijaykarthikeyan
                  wrote on last edited by Vijaykarthikeyan
                  #25

                  @jsulm So, the correct template should be look like this:

                  <qt-binary-folder>windeployqt.exe --qmldir <path-to-project-file> <path-to-Qt-build-folder>

                  1 Reply Last reply
                  0
                  • J.HilkJ J.Hilk

                    @Vijaykarthikeyan than you're most certainly missing the QML part during windeployqt call:

                    --qmldir <directory>

                    with <directory> being the full path to your main QML folder, as in where your main.qml is

                    otherwise how should the tool know what from QML you used in your application

                    V Offline
                    V Offline
                    Vijaykarthikeyan
                    wrote on last edited by
                    #26

                    @J-Hilk Thank you

                    1 Reply Last reply
                    1
                    • V Vijaykarthikeyan has marked this topic as solved on
                    • P Offline
                      P Offline
                      Puneeth_BR
                      wrote last edited by
                      #27

                      Hello @jsulm

                      while i am trying to execute the .exe file getting the below error

                      "This application failed to start because no Qt Platform plugin could be initialized. Reinstalling the application may fixe this Problem"

                      can you help me to sort it

                      jsulmJ 1 Reply Last reply
                      0
                      • P Puneeth_BR

                        Hello @jsulm

                        while i am trying to execute the .exe file getting the below error

                        "This application failed to start because no Qt Platform plugin could be initialized. Reinstalling the application may fixe this Problem"

                        can you help me to sort it

                        jsulmJ Offline
                        jsulmJ Offline
                        jsulm
                        Lifetime Qt Champion
                        wrote last edited by
                        #28

                        @Puneeth_BR Deploy your app properly first. See https://doc.qt.io/qt-6/deployment.html

                        https://forum.qt.io/topic/113070/qt-code-of-conduct

                        1 Reply Last reply
                        1

                        • Login

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • Users
                        • Groups
                        • Search
                        • Get Qt Extensions
                        • Unsolved