Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Re: Finding the full path of a c++ compiled executable in Visual C++

Reply
Thread Tools

Re: Finding the full path of a c++ compiled executable in Visual C++

 
 
Josephine Schafer
Guest
Posts: n/a
 
      07-21-2003

"Philip Morley" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I want my C++ executable to return the full path it was executed from on a
> Windows box using Microsoft Visual C++.
>
> In the past on Unix systems I have used argv[0], but on Windows argv[0]
> seems to return the DOS command, not the full path.
>
> Any suggestions on how to do this with Visual C++ would be appreciated.
>

Sorry it is offtopic here.
Please ask such questions on microsoft.public.vc.language newsgroup.

<offtopic>
Since I know the answer -
GetModuleFileName ()
</offtopic>

--
With best wishes,
J.Schafer


 
Reply With Quote
 
 
 
 
Philip Morley
Guest
Posts: n/a
 
      07-21-2003

"Josephine Schafer" <(E-Mail Removed)> wrote in message
news:bfgarg$dr0gj$(E-Mail Removed)-berlin.de...
>
> "Philip Morley" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > I want my C++ executable to return the full path it was executed from on

a
> > Windows box using Microsoft Visual C++.
> >
> > In the past on Unix systems I have used argv[0], but on Windows argv[0]
> > seems to return the DOS command, not the full path.
> >
> > Any suggestions on how to do this with Visual C++ would be appreciated.
> >

> Sorry it is offtopic here.
> Please ask such questions on microsoft.public.vc.language newsgroup.
>
> <offtopic>
> Since I know the answer -
> GetModuleFileName ()
> </offtopic>
>
> --
> With best wishes,
> J.Schafer
>
>


Will do in the future. Thanks for your reply.


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
executable path finding koranthala Python 3 09-01-2009 06:22 PM
Finding the full path of an executable Michael Hoffman Python 2 01-17-2009 10:00 AM
If I create a page, then it's compiled upon first request, where cani find the compiled code?? lander ASP .Net 5 03-05-2008 04:34 PM
Knowing the full path of the java executable/binary executing thecurrent java program Kaiser S. Java 3 07-12-2007 02:18 PM
g++ compiled C++ code called from gcc compiled C code Klaus Schneider C++ 1 12-02-2004 01:44 PM



Advertisments