Author Topic: How can I change terminal for console programs?  (Read 3663 times)

Offline Fulcrum

  • Single posting newcomer
  • *
  • Posts: 3
How can I change terminal for console programs?
« on: March 22, 2012, 09:25:14 am »
Hi!
I am using Code::Blocks on Windows XP, I have written simple program and tried to compile it. During the compiling there have been no errors but in result i have got just black screen without any way to terminate it except "killing" the process. After some googling i discovered that it could be caused by wrong choosing of terminal console. I guessed I should change it from "xterm" to some other like "gnome-terminal" maybe. But then I faced with a problem: changing terminal form is unactive (how it looks you can see on attachment picture). Is it OK and do I have any other way to choose another terminal?
« Last Edit: March 22, 2012, 09:46:40 am by Fulcrum »

Offline jens

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: How can I change terminal for console programs?
« Reply #1 on: March 22, 2012, 09:40:23 am »
The deactivated textcontrols are not used on windows, they are linux-only.

If your program has an error, that leads to an infinite loop, it would behave like you describe.

Offline Fulcrum

  • Single posting newcomer
  • *
  • Posts: 3
Re: How can I change terminal for console programs?
« Reply #2 on: March 22, 2012, 06:46:14 pm »
I am pretty sure that problem is not in my code. Because even this simple program does not execute:

#include <stdio.h>
main()
{
    printf ("Hello world!");
}

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7108
    • My Best Post
Re: How can I change terminal for console programs?
« Reply #3 on: March 23, 2012, 02:46:09 am »
Note: Before doing the following you need to verify your compiled program is NOT already running on your computer.
I suggest turning on Full Compiler logging and then doing a full rebuild of the CB project.

http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28errors%29#Q:_How_do_I_troubleshoot_a_compiler_problem.3F

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 32 bit.
On Debian Stretch, compiling CB Trunk against wxWidgets 3.0.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Fulcrum

  • Single posting newcomer
  • *
  • Posts: 3
Re: How can I change terminal for console programs?
« Reply #4 on: March 23, 2012, 08:03:42 pm »
stahta01, thanks a lot! Now it works :)