I managed to create a simple "hello world" console with QT Creator
Used Creator 2.4.1 and QT 4.8.0 for Windows 7
two ways to do it
Normal C ++
follow these steps
- File-New Project
- under select projects: other Project
- select "Normal C ++ project"
- enter project name 5.Targets select Desktop 'tick it'
- Project management just click next
- you can use C ++ commands as regular C ++
or
QT Console
- File-New Project
- under select projects: other Project
- select console QT application
- Goals select 'tick it' desktop
- Project management just click next
- add the following lines (all C ++ you need)
- add "#include" iostream '"
- add "using namespace std;"
- after QCoreApplication a (int argc, cghar * argv []) 10 add the variables and your program code.
example: for QT console "hello world"
file - project name of the new project project
other projects - QT console application
Goals choose a desktop
project management - next
the code:
#include <QtCore/QCoreApplication>
ctrl -R to run
used for the above MSVC 2010 (QT SDK) and minGW (QT SDK)
hope this helps someone
Since I just recently started using QT, I also searched Www for information and examples to get started with simple examples that are still looking for ...
code Mar 23 2018-12-23T00: 00Z
source share