Unable to open included files

9.4k Views Asked by At

I am using BorlandC and Windows 7.

When I compile the file, I am getting these errors:

Error Assign.C : Unable to open include file 'stdio.h'
Error Assign.C : Unable to open include file 'conio.h'
Error Assign.C : Unable to open include file 'dos.h'
Error Assign.C : Unable to open include file 'stdlib.h'

What am I doing wrong?

2

There are 2 best solutions below

0
On BEST ANSWER

check the bcc32.cfg file (should be in the same directory as bcc32.exe) It should contain:

-ID:\BorlandC\Include

Assuming that the include files can be found in D:\BorlandC\Include

0
On

So I was having the same problem and found the solution:

After installation of Borland, go to bin folder and -

  1. Create a bcc32.cfg file while will set the compiler options for the include and lib paths (-I and - L) switches to compiler by adding these lines:
-I"C:\Borland\Bcc55\include"
-L"C:\Borland\Bcc55\lib"

My bin folder is in C:\Borland\Bcc55

  1. Create a ilink32.cfg file which will set the linker option for the lib path by adding this line:
-L"C:\Borland\Bcc55\lib"

And check if path variable is set for borland compiler which I assume is already set if borland has been installed. Here's how to check -

  • Open Environment Variables in System Properties > Advanced tab.
  • Double click on Path in System Variables** section. Here it should have something like C:\Borland\Bcc55\Bin , and if it's not there, then add this path by clicking new. Click OK. And you're done.