?
Solved

ERROR:fatal.....\INCLUDE\STDIO.H 9: Unable to create output file  'Game.obj'       pls help

Posted on 2004-08-14
7
Medium Priority
?
10,748 Views
Last Modified: 2012-06-21
hi,
I am using turbo C++ Ms mode compiler. It was working fine untill yesterday. below is the program that i wrote last week and i tried to run this today (it was working fine last week)and it gave me the following error.
fatal.....\INCLUDE\STDIO.H 9: Unable to create output file  'Game.obj'
I can run some programs but not all, below is the one of the few programs that i cannot run.

#include<stdio.h>
#include<conio.h>
void main()
{
int i=21,n,k,sum=0;
clrscr();
while(i>1)
{
printf ("\n\nSelect any number from 1,2,3,4");
scanf ("%d",&n);
if(n>4)
{
printf ("Error");
break;
}
k=5-n;
printf ("\n\nComputer assigns %d ",k);
i=i-(k+n);
sum=sum+k+n;
printf ("\n\nTotal match sticks choosen= %d",sum);
if(i==1)
printf ("\n\nThere is only one more remainning so you lost the game");
}
getch();
}
please help me to find the problem,
thanks
deep
0
Comment
Question by:deepthiji
  • 4
  • 3
7 Comments
 
LVL 9

Expert Comment

by:ankuratvb
ID: 11803798
Hi deep,

This error occurs due to 2 reasons:

Either the disk is full,

OR

The output directory does not exist.

Most probably,your output directory has been set to a directory which doesnt exist.

If you're using the IDE,goto Options->Directories->Output Directory
and specify a valid path.
0
 
LVL 9

Expert Comment

by:ankuratvb
ID: 11803806
If you're using tcc,
use :
tcc -Ic:\tc\include -Lc:\tc\lib -nc:\tc filename.c

-n[Output Directory]
-I[Include Directory]
-L[Lib Directory]
0
 
LVL 3

Author Comment

by:deepthiji
ID: 11804354
I am using Turbo C++ IDE,
 I went to Options->Directories->
These are the entries there.

Include Directories...... C:\TC\INCLUDE

Library Directories....... C:\TC\LIB

Output Directory......     Nothing here(What should i Add Here Newbie^_^)

Source Directories....... Nothing here toooo
>>The output directory does not exist

I dont have problem running all the programs, If the output directory does not exist , should i have problem running all the programs?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 9

Accepted Solution

by:
ankuratvb earned 2000 total points
ID: 11804792
Specify any valid directory as the output directory.

I generally create a directory to store the executables.For e.g. create a dir. called EXE in C:\TC and make the output directory entry as C:\TC\EXE

You can specify any existing directory path as the output directory.That dir. will be used to store the obj and the exe files for the source files that you compile and run.

You can leave the source directory entry blank.

>>
I dont have problem running all the programs, If the output directory does not exist , should i have problem running all the programs?
<<

If the o/p dir. does not exist,you should have a problem running all your programs.Try giving a valid path in the o/p dir. and see if all your programs are working.

If some of the programs are working,do check for hard disk space(this might be due to no space caused by disk full)
0
 
LVL 3

Author Comment

by:deepthiji
ID: 11804833
Coool That Worked... Thanks a lot for the help..
Points for you.>)
0
 
LVL 3

Author Comment

by:deepthiji
ID: 11804846
Earlier all the .OBJ and .EXE files were in the bin folder, I think now it will go to the EXE folder right/?
anyway everything is working fine now
thanks
deep
0
 
LVL 9

Expert Comment

by:ankuratvb
ID: 11804876
>I think now it will go to the EXE folder right/?

yeah.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tutorial is posted by Aaron Wojnowski, administrator at SDKExpert.net.  To view more iPhone tutorials, visit www.sdkexpert.net. This is a very simple tutorial on finding the user's current location easily. In this tutorial, you will learn ho…
Summary: This tutorial covers some basics of pointer, pointer arithmetic and function pointer. What is a pointer: A pointer is a variable which holds an address. This address might be address of another variable/address of devices/address of fu…
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to create, access, and change arrays in the C programming language.
Suggested Courses

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question