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. [Solved] Build problem in Qt Creator
QtWS25 Last Chance

[Solved] Build problem in Qt Creator

Scheduled Pinned Locked Moved General and Desktop
10 Posts 3 Posters 3.2k Views
  • 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.
  • H Offline
    H Offline
    Hareen Laks
    wrote on last edited by
    #1

    Hi everyone,

    I'm using Qt Creator 2.4.1 Based on Qt 4.7.4 on windows 7.

    When I run or build the application it is not working the way it should.

    For example

    qDebug() << "This is first";

    shows the text 'This is first'. But even if I change it to

    qDebug() << "This is second";

    sometimes it still shows the text 'This is first'.

    This is not occurring every time.

    Is there any way to fix it?

    Thanks in advance.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Do you mean in the console output of QtCreator ? Did you clear the console output ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • H Offline
        H Offline
        Hareen Laks
        wrote on last edited by
        #3

        Thanks for replying..

        Not only in the console output. Sometimes it not build the changes of source code.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Are you sure the change have been saved ?

          Do you run the application using the CTRL+R or the green arrow on the Application Output Pane ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • H Offline
            H Offline
            Hareen Laks
            wrote on last edited by
            #5

            I set to autosave the changes when press large green arrow on sidebar. So I'm not manually save.

            I run the application by large green arrow not an small one.

            The problem is the results are not repeatable every time. Sometimes it build the changes and sometimes not. The problem occurs today. I'm working with qt since few months without this type of problem.

            Thank you very much for helping me..

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Is your code in a static library ?

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              0
              • H Offline
                H Offline
                Hareen Laks
                wrote on last edited by
                #7

                Sorry for the delay. I'm out of office.

                Difficult question for me. I'm beginner. :)

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  In that case, can you describe your project (template used etc...) ?

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0
                  • K Offline
                    K Offline
                    koahnig
                    wrote on last edited by
                    #9

                    @Hareen Laks

                    It looks to me that your application is not compiled every time you have changed the code. You have apparently a very simply application with presumably just some few files, so it has only a limited complexity. So it is a bit strange.

                    Whenever you change code you should save it (ctrl+s to save one file, ctrl+shift+s for all files changed) before compilation (ctrl+b or ctrl+shift+b). You can perform the same tasks through the menu. Sometimes it may be helpful to do a complete recompile or a "Run qmake". Especially switching between release and debug modes seems sometimes to confuse qt creator. The recompile and rerun of qmake recommendation are based on my personal experience with large projects on windows 7 with qt creator 2.6.0. Therefore, I find it a bit strange that similar problems are existing with smaller projects.

                    Furthermore, you might want to update your installation. From my viewpoint at least qt creator which is now in version 2.7. You may to continue to use the new creator version with Qt 4.7.4 if you do not want to change that one for any reason. However, when starting with Qt there are probable no restrictions (other than limited disk resources on old HW) to install the new Qt SDK with e.g. MinGW compiler, Qt creator and Qt 5. Having a consistent new setup might solve also some problems. BTW if you have enough disk space, you can leave Qt 4.7.4 on your machine and build with both tool chains.

                    Vote the answer(s) that helped you to solve your issue(s)

                    1 Reply Last reply
                    0
                    • H Offline
                      H Offline
                      Hareen Laks
                      wrote on last edited by
                      #10

                      @ SGaist, koahnig

                      I reinstall the Qt creator and still it is working fine.

                      But unfortunately, I haven't know idea because of what it is occurred.

                      Thank you very much for both of you..

                      1 Reply Last reply
                      0

                      • Login

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