Turboc++ / codeblocks

i have windows 7. i downloaded dosbox turbo c++. but when i try to run a graphics.h header file . it does not run.i also downloaded codeblocks.
but it said "this file has not been built yet".
what is the problem??
5 answers Last reply
More about turboc codeblocks
  1. When you attempt to run a program from within an IDE, it has to go through several stages before it actually launches and begins running. These stages are generally compile, build and run.

    Compile basically checks for any errors, and if none are found (or they're minor enough to only be warnings), the IDE will then translate your program into machine language to then be ran. The compile command only works on the current file you actively have open within the editor; it does not compile your entire project.

    Because you can, and usually do, have more than one file in a program, you must compile the entire project before it can be ran. This is done by selecting "build", which should be somewhere near the compile option within the menus. Building a project also links necessary files, such as libraries, to your program. If everything is all good, you can then select the run command, which then creates an executable and launches your program.

    So you need to build the program, or in other words compile the entire project, before you can successfully run your program.
  2. "fatal error: graphics.h: No such file or directory" this is what i got.
    cant i run graphics program in codeblocks
  3. Check that that header exists in a diectory listed in your INCLUDE path. If not, modify the path.
  4. Make sure that you've imported the graphics.h file to your project, and then add "#include <graphics.h>" (but without the parenthesis) at the beginning of your main.cpp file; or whatever you've named the main file.

    Build and then run.
  5. i included the graphics header file which showed error message "fatal error: graphics.h: No such file or directory" how to modify the path?@Ijack
Ask a new question

Read More

Programming Windows 7 Graphics Apps