Solved

Get program path

Posted on 1998-12-02
3
171 Views
Last Modified: 2011-09-20
How can I find out where a program is currently running (path) from within that program ?
0
Comment
Question by:ymailhot
  • 2
3 Comments
 
LVL 10

Accepted Solution

by:
viktornet earned 50 total points
ID: 1349069
You can do like so...

MyExeName := Application.ExeName;

That's the path and the exe's name..if you want to extract the path just use the following example...

Path :=    ExtractFilePath(Application.ExeName);

Cheers,
Viktor
0
 

Author Comment

by:ymailhot
ID: 1349070
Thank you.
0
 
LVL 10

Expert Comment

by:viktornet
ID: 1349071
no problem
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question