Can't run program from QT Creator says it exited or Cannot obtain a handle to the inferior
-
wrote on 23 Oct 2012, 05:59 last edited by
When I try to run my program it either says it exited with code 0 or it says Cannot obtain a handle to the inferior: The parameter is incorrect. I can take the built exe and run it just fine without QT Creator. I tried rebooting my pc, close/reopen QTCreator, building with different compiler, and cleaning the project.
What's going on here?
-
wrote on 23 Oct 2012, 06:18 last edited by
Once i had faced a problem like this... I just did like this.. go to Projects, and check your Qt Version and Tool Chain properties and change it to your needs... Then it worked fine for me... :)
-
wrote on 23 Oct 2012, 06:37 last edited by
The tool chains and things are set up, it builds just fine. And the exe it builds when run from the folder directly runs fine. But QT doesn't run it.
-
wrote on 23 Oct 2012, 06:41 last edited by
Does it says that any dll's required??
-
wrote on 23 Oct 2012, 06:44 last edited by
I deleted the build folders and the .user files, still doing the same thing after restart.
-
wrote on 23 Oct 2012, 06:45 last edited by
No, the .dlls are fine. Strangly I installed 2.6rc and it worked after setting up the kits, it built and run it fine a few times and now im getting the same error again.
-
wrote on 23 Oct 2012, 20:23 last edited by
I've uninstalled and reinstalled everything QT and still getting this problem. QT is not usable like this.
-
wrote on 8 Nov 2012, 17:25 last edited by
I have the same problem. Qt 4.8.2 + Qt-Creator 2.5.2 under WinXp.
I ran into it in two projects: both console and finishes very quickly. One of them is a test project, the other - a console project, which does not call QCoreApplication::exec() (I checked a project, which calls it - no problem there).
After rebuilding - first launching finishes well. In all others qt-creator thinks that the program is still running (and writes "Cannot obtain a handle to the inferior" in debug console) though actually it does not.
It is annoying. -
wrote on 4 Dec 2012, 10:43 last edited by
Hi there,
is there any solution to this problem?
I observed the same problem here, but the message only occurs during my QTest's.
I assume that the QTEST_APPLESS_MAIN sometimes runs into that error-message.
It seems to correlate with the presence or absence of a QCoreApplication, because if i use the same code within my Console-application the message never occurs.
Also Amartel mentioned, that his project using QCoreApplication runs without problems...Should one file a Bug-Report here?
-
wrote on 7 Mar 2013, 11:07 last edited by
I see the same on Win7 using 5.0.1. For me there has been nothing but errors with 5.0.1. For instance debug/release paths are mixed up when building, this error, uic seems to create invalid ui_foo.h files etc.
-
wrote on 8 Mar 2013, 04:37 last edited by
If you go to Projects -> build & Run and then check the Run settings, make sure that the Executable being called in the Run configuration is the same one for the build configuration e.g. ./debug/<your_app.exe> (use absolute path) for a debug configuration
-
wrote on 8 Mar 2013, 04:43 last edited by
There have been a few related issues. I had the "handle" issue among others when moving to 5.0.1. I resolved using the following steps.
- Clean project
- Close QtCreator
- Remove Release/Debug Folder from app directory
- Delete xxx.pro.user file (lives in app directory)
- Manually delete Makefile, Makefile.Debug, Makefile.Release (If still there)
- Open Qt Creator again and open your project. It should now be asking you to reconfigure your project build settings.
Also, check your environment variables – ensure they are updated for 5.0.1 paths.
"Reference to similar problem":http://qt-project.org/forums/viewthread/25326/
"Reference to another similar problem":http://qt-project.org/forums/viewthread/25058/
-
wrote on 4 Nov 2013, 11:54 last edited by
Thanks Wakeuky for step by step reply.
It is not working in my case.
I could debug/run my project; made some changes in the code and then this error appeared.
Can there any other reasons for this problem? -
wrote on 4 Nov 2013, 12:37 last edited by
Hi tesmal4, it has been quite a while since I have seen this issue. This issue occurred for me when I had created a project under the 4.8.4 environment and tried opening the project under 5.0.1.
I am no using the latest 5.1.1 release and have had no issues of the sort. What version was your project created under?
What version are you currently trying to use? -
wrote on 4 Nov 2013, 15:07 last edited by
Qt 4.7.4 for Desktop MinGW 4.4 and Qt Creator 2.4.1 . I did not change any configuration for the project. I only made changes in the cpp file.
-
wrote on 5 Nov 2013, 16:24 last edited by
I accidentally deleted DLL path. Now its working fine.
Thanks for your help and advice.Regards
-
wrote on 21 Jul 2015, 13:04 last edited by
teslmai4: I have the same kind of problem with Qt 5.5.0. Can you please indicate what DLL path you delete?
-
wrote on 21 Feb 2016, 10:57 last edited by
I have same issue.
And I copy my own DLL file to app-out-dir.
then this issue can to solute. -
wrote on 18 Mar 2016, 20:16 last edited by
Seems likely that it is not a real "problem" but can be due to your application exiting too quickly when being run under QtCreator, please see this link
(http://stackoverflow.com/questions/21539162/qt-creator-code-is-running-but-i-get-an-error-message-from-the-ide