Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QMainWindow based app dissapears in release
Forum Updated to NodeBB v4.3 + New Features

QMainWindow based app dissapears in release

Scheduled Pinned Locked Moved Unsolved General and Desktop
10 Posts 4 Posters 918 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.
  • J Offline
    J Offline
    JohnCu
    wrote on last edited by
    #1

    Hi, I have just built an app, based on QMainwindow in release mode (x64) in visual studio 2019. I have also used "windeployqt.exe --quick ." command via QT x64 command. While launching I was prompted to provide a few dlls: Qt5PrintSupport.dll, and 2 other libraries. After launching the app, it works well, and after pressing some buttons, and performing part of necessary operations (as well as associated data visualization) the GUI simply disappears.
    Are there any tools to track the problem down?
    In visual studio in debug and release everything is fine. Only launching app as a standalone .exe file the problem occurs.
    Thanks

    JonBJ J.HilkJ 2 Replies Last reply
    0
    • J JohnCu

      Hi, I have just built an app, based on QMainwindow in release mode (x64) in visual studio 2019. I have also used "windeployqt.exe --quick ." command via QT x64 command. While launching I was prompted to provide a few dlls: Qt5PrintSupport.dll, and 2 other libraries. After launching the app, it works well, and after pressing some buttons, and performing part of necessary operations (as well as associated data visualization) the GUI simply disappears.
      Are there any tools to track the problem down?
      In visual studio in debug and release everything is fine. Only launching app as a standalone .exe file the problem occurs.
      Thanks

      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by
      #2

      @JohnCu
      Very small chance of an error being reported in Event Viewer, you should at least check there.

      J 1 Reply Last reply
      0
      • J JohnCu

        Hi, I have just built an app, based on QMainwindow in release mode (x64) in visual studio 2019. I have also used "windeployqt.exe --quick ." command via QT x64 command. While launching I was prompted to provide a few dlls: Qt5PrintSupport.dll, and 2 other libraries. After launching the app, it works well, and after pressing some buttons, and performing part of necessary operations (as well as associated data visualization) the GUI simply disappears.
        Are there any tools to track the problem down?
        In visual studio in debug and release everything is fine. Only launching app as a standalone .exe file the problem occurs.
        Thanks

        J.HilkJ Offline
        J.HilkJ Offline
        J.Hilk
        Moderators
        wrote on last edited by
        #3

        @JohnCu said in QMainWindow based app dissapears in release:

        --quick

        so you use qml in your app ?
        give the deployment tool the path to your qml files via --qmlDir


        Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


        Q: What's that?
        A: It's blue light.
        Q: What does it do?
        A: It turns blue.

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

          @JohnCu said in QMainWindow based app dissapears in release:

          --quick

          so you use qml in your app ?
          give the deployment tool the path to your qml files via --qmlDir

          J Offline
          J Offline
          JohnCu
          wrote on last edited by
          #4

          @J-Hilk No, I dont think so. So how should windeployqt.exe call look like, assuming that I am not using qml?

          J.HilkJ 1 Reply Last reply
          0
          • J JohnCu

            @J-Hilk No, I dont think so. So how should windeployqt.exe call look like, assuming that I am not using qml?

            J.HilkJ Offline
            J.HilkJ Offline
            J.Hilk
            Moderators
            wrote on last edited by
            #5

            @JohnCu
            I may have miss understood.

            You do not use QML?
            What as your exact windeployqt command ?


            Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


            Q: What's that?
            A: It's blue light.
            Q: What does it do?
            A: It turns blue.

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

              @JohnCu
              I may have miss understood.

              You do not use QML?
              What as your exact windeployqt command ?

              J Offline
              J Offline
              JohnCu
              wrote on last edited by JohnCu
              #6

              @J-Hilk I am not using QML. I wrongly used --quick option. So how should I use it in a correct way? How windeployqt command should look like?

              1 Reply Last reply
              0
              • JonBJ JonB

                @JohnCu
                Very small chance of an error being reported in Event Viewer, you should at least check there.

                J Offline
                J Offline
                JohnCu
                wrote on last edited by
                #7

                @JonB e974c3da-53d9-4b86-8dc9-9c10b52efe9e-image.png
                I found something like that... What does it mean?
                I performed following cmd commands:
                sfc /scannow
                DISM /Online /Cleanup-Image /RestoreHealth
                But the problem still exists...

                JonBJ 1 Reply Last reply
                0
                • J JohnCu

                  @JonB e974c3da-53d9-4b86-8dc9-9c10b52efe9e-image.png
                  I found something like that... What does it mean?
                  I performed following cmd commands:
                  sfc /scannow
                  DISM /Online /Cleanup-Image /RestoreHealth
                  But the problem still exists...

                  JonBJ Offline
                  JonBJ Offline
                  JonB
                  wrote on last edited by JonB
                  #8

                  @JohnCu
                  It means your program crashed! It has a memory access violation (e.g. bad pointer value) at offset 0x02f5da in the executable. Which probably won't help you much to track it down in the source code, but at least you know why it is disappearing!

                  J 1 Reply Last reply
                  1
                  • JonBJ JonB

                    @JohnCu
                    It means your program crashed! It has a memory access violation (e.g. bad pointer value) at offset 0x02f5da in the executable. Which probably won't help you much to track it down in the source code, but at least you know why it is disappearing!

                    J Offline
                    J Offline
                    JohnCu
                    wrote on last edited by
                    #9

                    @JonB Ok! I will try to track it down ! however in debug mode/release mode in visual there is no such issue...

                    JKSHJ 1 Reply Last reply
                    0
                    • J JohnCu

                      @JonB Ok! I will try to track it down ! however in debug mode/release mode in visual there is no such issue...

                      JKSHJ Offline
                      JKSHJ Offline
                      JKSH
                      Moderators
                      wrote on last edited by
                      #10

                      @JohnCu said in QMainWindow based app dissapears in release:

                      in debug mode/release mode in visual there is no such issue...

                      Here's a starting point: https://exceptionshub.com/program-only-crashes-as-release-build-how-to-debug.html

                      Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

                      1 Reply Last reply
                      2

                      • Login

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