Linking 3 files in Borland C 3.11

This is a discussion on Linking 3 files in Borland C 3.11 within the C++ Programming forums, part of the General Programming Boards category; Hello.
Please help me solve this problem because I'm getting very nervous allready. It's very simple, but still it gives ...

And you're allready guessing I want to link them into one exe file.
The problem is, I'm bound to use BorlandC 3.11 compiler (which is new to me), and I still don't believe I didn't manage to do it myself, but it's true.
All 3 files are in the same directory C:\BC31\BIN, search paths for include and library files are correct, and point to that dir, but still command

> All 3 files are in the same directory C:\BC31\BIN
Bad idea - create a separate directory (say c:\code) where all your code lives. There's no need to store your source code in the same directory as your compiler, if you've set everything up.

Also, does compiling a simple "hello world" type program compile OK?

> The problem is, I'm bound to use BorlandC 3.11 compiler
Never a good sign, if your tutor insists on using a particular compiler, especially an old one.

> All 3 files are in the same directory C:\BC31\BIN
Bad idea - create a separate directory (say c:\code) where all your code lives. There's no need to store your source code in the same directory as your compiler, if you've set everything up.

I agree it's a bad idea, but it was just for the testing purposes.
Now, I've tried to put those files in c:\code and modify search paths, but problem remains the same.

Originally Posted by Salem

Also, does compiling a simple "hello world" type program compile OK?

Yes, as long as everything is in the same file (or one .cpp file (main program) and one header) it's OK. Linking is the problem.

Originally Posted by Salem

> The problem is, I'm bound to use BorlandC 3.11 compiler
Never a good sign, if your tutor insists on using a particular compiler, especially an old one.

I thought that problem is most certanly in command line parameters, .cfg files, or something like that. Now, you made me recheck the code, so I found the error, subtle but important.
The bug was inline specifier in method definition(in classX.cpp file). Why that is fine with compiler, and makes problems during linking, don't know and it doesn't matter.