Hi all,
Is there a method that will tell me the pathname of where the current process resides?
I know there is a GetModuleFilename that will tell me the exact path and the filename of the current process, but i just want the path.
Thanks![]()
This is a discussion on How to find the current path? within the C++ Programming forums, part of the General Programming Boards category; Hi all, Is there a method that will tell me the pathname of where the current process resides? I know ...
Hi all,
Is there a method that will tell me the pathname of where the current process resides?
I know there is a GetModuleFilename that will tell me the exact path and the filename of the current process, but i just want the path.
Thanks![]()
Take the return string from GetModuleFilename() and chop off the filename -- what you have left is just the path.
But if you want the current working directory, you can get that from getcwd() or win32 api GetCurrentDir().