How to run Turbo C or C++ in my DOS window ( Command Prompt)

In this article I will explain the procedure with screen shoots and Video tutorial to run Turbo C or C++ in my DOS window (Command Prompt). So you no need to copy your C or C++ source code to TC directory and then compile or run. Only you need to go to your source file with Command Prompt and then type “tc” command and compile or run your source codes and the object file or output file is automatically placed there.

To set Turbo C or C++ run by command in DOS window (Command Prompt) follow following steps

To run Turbo C or C++ in DOS window (Command Prompt) we need to set Environment Variable for Turbo C or C++.
At first install the Turbo C or C++ in your C:/ directory and then go to BIN folder or where the TC.EXE file is find. ( Means that TC.EXE may be in TurboC/ )
After that copy the URL from address bar.( which is as shown in figure).

Turbo C or C++ URL copy to run in DOS window (Command Prompt)

After that open System Properties
To open System Properties open Desktop and right click on My Computer Icon and then click on Properties.
If you use Window 7 then click on “Advanced System Settings” which is left side bar.
and if you use Window XP then no need to open “Advanced System Settings”.
After that open “Advanced” tab in “System Properties” window.

System properties window for environment variables

In Advanced tab click on “Environment Variables” button.
And select “Path” variable and click on “edit” button.

Environment variables window, select path variable and edit

After click on edit button “Edit System Variable” window is opened. In this window in variable value box
after ; past your Turbo C or C++ URL.

Edit system variable with address of turbo c tc file path

Click on OK and and all window close with click on OK button.
You done the now you can open your Turbo C or C++ in DOS window (Command Prompt) with “tc” command.
As shown in figure.

tc command in DOS window (command prompt)

Press enter and work you in turbo c or c++.

turbo c or c++ open in dos window (command prompt)

For better understand watch this video.

If you face any problem then feel free and contact me.

One Response
  1. April 23, 2012