Current Path

Delphi 1
How to get the actual Path? I should know where my .exe is in the directory..

Thanx Choli
Choli100298Asked:
Who is Participating?
 
dotanCommented:
ExtractFilePath(ParamStr(0))
0
 
BlackDeathCommented:
or:
sStartUpPath := ExtractFilePath(Application.ExeName);

and for the current directory use the API-function

GetCurrentDirectory(bufLength, buf);

with bufLength specifying the size of the buffer you will receive the directory in and
buf the address of the above mentioned buffer

- dotan:
you've been about 1 ms faster than me; the same second i tried to post this, the answer was auto-rejected from the system and so i post this comment.
this just as declaration why i post the same as you; it's not because i didn't read your answer...

;-)))

byebye,

Black Death.
0
 
kretzschmarCommented:
hi choli,

all are faster than me

your_string_var := ExtractFilePath(ParamStr(0));

meikl
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.