Unable to run any code in QTCreator
-
Hi all
I just started a QT course and am having some problem running code in QTCreator. When I try to run any code(even QT examples from my textbook) I don't get any output. it just says starting C:<filePath> at the bottom. Adny idea what I could be doing wrong?
Thanks in advance -
Hi,
please provide more informations about your development environment (Qt version, compiler, IDE version) and operating system.
As you maybe already experienced the Qt SDK is available on many different Linux, Unix; QNX, Windows, Mac OS X and mobile platforms.
ciao,
Chris -
Hi Chris i'm using Windows 7 ultimate 32 bit, QTCreator v2.2.0 QT SDK 2010.04 a
-
Hi and welcome to devnet,
That SDK and Creator version are 4 years old, unless you are tied to it please consider installing the latest version available "here":http://qt-project.org/downloads
-
Hi yes I am tied to it as I have to use the version given out by my lecturer. It seems to be working fine for everyone else doing this course...
-
I just spoke to my lecturer and he said it's fine to use the latest version as long as the code could be compiled on the 4-year old version. Would that work?
-
Then, download also Qt 4.8.5 or 4.8.6 and use that one, you'll be on the safe side in that case.
-
Thanks a lot will do that. How would I get the new QTCreator to compile using QT 4.8?.5 or 6?
-
Absolutely no need to recompile Qt Creator nor Qt. Just use it and add your Qt 4.8.X to the known Qt version and make a Kit out of it.
-
How do I go about doing that? I tried to install QT 4.8.5 but i'm getting a warning when I click install "could not find a valid C:\mingw\include\w32.h" any idea how I can fix that?
Thanks -
What packages did you use ?
-
When I installed mingw I only installed the G++ package
-
If you can avoid installing external MinGW. The latest Qt installer provides a Qt 5 version with MinGW also in the package, so you have everything in one place.
Doing so you would need to install the "4.8.6 snapshot":http://download.qt-project.org/snapshots/qt/4.8/2014-02-17_484/qt-opensource-windows-x86-mingw482-4.8.6-2014-02-17-484.exe so you can directly use it. 4.8.5 is built with MinGW 4.6 which is not compatible with 4.8
-
I finally finished downloading the latest version of QT, but When I try to #include QApplication or QLabel I get an error message saying no such file or directory... any idea what i'm doing wrong? Also how would I create a kit of QT 4.8.6?
Thanks again -
Just go in the Kit panel, create a new one and select Qt 4.8.6 as the Qt version to use with it
-
Now when I try to install QT 4,8.6 it complains that g++ isn't installed with mingw. This is the default mingw that came with the latest version of QT. The warning says that it might not work should I just install it anyway? Or is there a way to add g++ to mingw
-
I'am not sure I'm getting you right. Did you install the 5.2 MinGW edition ?
-
So it turns out the issue was Avast antivirus's realtime protection. Thanks again for all the replies.