replica nfl jerseysreplica nfl jerseyssoccer jerseyreplica nfl jerseys forums.silverfrost.com :: View topic - How to get the installation path of the running exe?
forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to get the installation path of the running exe?

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General
View previous topic :: View next topic  
Author Message
johannes



Joined: 21 Jan 2011
Posts: 65
Location: Leimen, Germany

PostPosted: Sun Oct 27, 2013 10:53 am    Post subject: How to get the installation path of the running exe? Reply with quote

Hi all,
given I run a Fortran exe. Now I want to request its installation path from the running code itself.
Is this possible, without intermediate parsing a task manager output?
Regards, johannes
Back to top
View user's profile Send private message
LitusSaxonicum



Joined: 23 Aug 2005
Posts: 2402
Location: Yateley, Hants, UK

PostPosted: Sun Oct 27, 2013 11:06 am    Post subject: Reply with quote

Easy enough:

Code:
       CHARACTER*(256) PROG_PATH_NAME
       INCLUDE <WINDOWS.INS>
       CALL GET_PROGRAM_NAME@ (PROG_PATH_NAME)


Eddie
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 8211
Location: Salford, UK

PostPosted: Sun Oct 27, 2013 4:15 pm    Post subject: Reply with quote

Also GET_COMMAND and GET_COMMAND_ARGUMENT.
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> General All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group