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. Installation of Qt Creator (Any version)
Forum Updated to NodeBB v4.3 + New Features

Installation of Qt Creator (Any version)

Scheduled Pinned Locked Moved General and Desktop
27 Posts 4 Posters 7.4k 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.
  • SGaistS Offline
    SGaistS Offline
    SGaist
    Lifetime Qt Champion
    wrote on last edited by
    #10

    Did you create a new Qt Widget Application like a suggested ?

    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
    • J Offline
      J Offline
      jafarabadi.qt
      wrote on last edited by
      #11

      Hi dear SGaist :*

      astello_, Dear friend follow me in below steps:

      • Run Qt Creator
      • Click on New project
      • Select Qt Widgets Application and press Choose
      • Type a name for ur project and click on Next
      • In this window select compiler and press Next **Note that if you use from MSVC you should download version of Qt Creator which is compatible with Visual Studio.
      • Here just click on Next and after it Finish
      • Look left side of Qt Creator and open main.cpp from Source folder
      • Add my new code line in main.cpp then Run it
        @
        #include "mainwindow.h"
        #include <QApplication>

      #include <iostream> // Add This Line
      using namespace std; // Add This Line

      int main(int argc, char *argv[])
      {
      QApplication a(argc, argv);
      MainWindow w;

      cout<<"Hello World :)"<<endl; // Add this line

      w.show();
      return a.exec&#40;&#41;;
      

      }
      @

      • After run "Hellow World :)" will print on Application output in bottom of Qt Creator
      • say ur experience after u doing it
      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #12

        @ a.jafarabadi Qt Creator can use MSVC or MinGW indifferently. It's Qt's version which must match.

        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
        • J Offline
          J Offline
          jafarabadi.qt
          wrote on last edited by
          #13

          [quote author="SGaist" date="1410293290"]@ a.jafarabadi Qt Creator can use MSVC or MinGW indifferently. It's Qt's version which must match.[/quote]

          dear SGaist yes, it's true. we all now always the least version is better :) and the least version have some sub-version which you better now. in that post i want to say if my friend using from visual studio compiler it's good that download Visual studio sub-version of qt

          1 Reply Last reply
          0
          • A Offline
            A Offline
            astello_
            wrote on last edited by
            #14

            Thank you for your help.

            You two are right. If I follow these steps I can do it, but what I need is to open an Empty Qt project.

            Here, when I write my code and compile it, it is impossible to run in terminal.

            I get the message: "Press return to close this window".

            I feel that we are close to the solution but I can't find it.

            What do you think?

            Thank you again.

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

              What do you mean by run in terminal ?

              In any case, running an application outside Qt Creator requires the same step as you would have to do in order to deploy it on another computer.

              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
              • A Offline
                A Offline
                astello_
                wrote on last edited by
                #16

                Run in terminal = Projects (on the left side Menu) -> Run -> Run in terminal marked

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

                  What project did you create ?

                  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
                  • A Offline
                    A Offline
                    astello_
                    wrote on last edited by
                    #18

                    Empty Qt project

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

                      Do you mean a console application ?

                      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
                      • A Offline
                        A Offline
                        astello_
                        wrote on last edited by
                        #20

                        Yes.

                        New File/project -> Other project -> Empty Qt project. That's what I need.

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

                          Then it's not a console application. You asked for an empty project so you have to write everything yourself. What did you write for this project ?

                          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
                          • A Offline
                            A Offline
                            astello_
                            wrote on last edited by
                            #22

                            #include <iostream>

                            using namespace std;

                            int main()
                            {
                            cout << "Hello" << endl;

                            }

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

                              In what file did you write that ?

                              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
                              • A Offline
                                A Offline
                                astello_
                                wrote on last edited by
                                #24

                                main.cpp

                                1 Reply Last reply
                                0
                                • JKSHJ Offline
                                  JKSHJ Offline
                                  JKSH
                                  Moderators
                                  wrote on last edited by
                                  #25

                                  Hi,

                                  If you want a console application, you need to create a console application project, not an empty project.

                                  File -> New File or Project... -> Applications -> Qt Console Application

                                  After that, you can remove QCoreApplication from main.cpp if you don't want to use Qt classes.

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

                                  1 Reply Last reply
                                  0
                                  • A Offline
                                    A Offline
                                    astello_
                                    wrote on last edited by
                                    #26

                                    IT WORKS!! Not as I expected in the beginning, but it is useful.

                                    Thank you very much.

                                    :)

                                    1 Reply Last reply
                                    0
                                    • J Offline
                                      J Offline
                                      jafarabadi.qt
                                      wrote on last edited by
                                      #27

                                      if you want develop using native c++ it's better to use from an c++ IDE which is simplest from Qt Creator...
                                      We download, install and use from Qt because of it's useful libraries...
                                      i hope you can find best answer :)

                                      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