Find actual path of program (EXE)

I am trying to determine the path that the exe file was called from, i.e. the compiled C program may be in a directory different from the current one.
How do I find the EXE's true path? (sounds like enlightment for programs :)
Compiler is BC++ 3.1 for DOS.

Here is an answer I've seen on a newsgroup regarding...
I hope this helps you. if you're stuck - tell me - I'll explain.
So, here is the question (just as yours) and the proposed ansewr:
---------------------------------------------------------------------------------------------------

>I am having problems in getting the full path of the application
>executable when the application comes up.
>
>m_pszExeName of the CWinApp contains only the name of the executable,
>without extention or the full path.
>
>How can i get the above with the full executable name, or atleast the
>full path the directory which contains the executable.

At this point, if you're using MFC, it's easy enough to convert the
character buffer into a CString, if that's what you want.
----------------------------------------------------------------------------------------------------------------------

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

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…

This is a short and sweet, but (hopefully) to the point article. There seems to be some fundamental misunderstanding about the function prototype for the "main" function in C and C++, more specifically what type this function should return. I see so…