4

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?

Johan
  • 74,508
  • 24
  • 191
  • 319
zubair
  • 185
  • 3
  • 15
  • I've never used Borland, have you specified include directories? – Marlon Apr 17 '11 at 03:28
  • In include folder all the files stdio.h, conio.h , dos.h and stdlib.h are exist i have seen these files manually – zubair Apr 17 '11 at 03:34
  • Which version of BorlandC++ are you using? Have you checked if the file that gives errors, has an override of the include directories? Can you compile successfully other code, like the BC examples? – Jogy Apr 17 '11 at 10:05

2 Answers2

4

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

David Dean
  • 2,682
  • 23
  • 34
0

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.