🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #17604

Re: How to get application's directory?

#17604
From: Remy Lebeau (TeamB)
Date: Sat, 22 Mar 2003 20:25
14 lines
1696 bytes
You can't always rely on that, either, as other controls outside your
control, such as TOpenDialog and the FileCtrl controls under the Win3.1
palette, can (and usually do) change the current directory internally.
Using ExtractFilePath() with Application->ExeName is the only guaranteed way
to get the application's directory regardless of any changes that are made
to the process.


Gambit

"Rodolfo Frino - Stargate Software" <starcinema@eftel.com> wrote in message
news:3e7c7c8c@newsgroups.borland.com...
> GetCurrentDirectory() should be called before changing the
> Current Directory (I forgot to mention that)<snip>
Technical Details
Message-ID: <3e7cc472$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail
References: <3e7a7800$1@newsgroups.borland.com> <3e7a8e39@newsgroups.borland.com> <3e7ae7af$1@newsgroups.borland.com> <3e7c7c8c@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,440cb76ba9be739c
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-03-23 23:42:51 PST
From: "Remy Lebeau \(TeamB\)" <gambit47@yahoo.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <3e7a7800$1@newsgroups.borland.com> <3e7a8e39@newsgroups.borland.com> <3e7ae7af$1@newsgroups.borland.com> <3e7c7c8c@newsgroups.borland.com>
Subject: Re: How to get application's directory?
Date: Sat, 22 Mar 2003 12:25:30 -0800
Lines: 16
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1106
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106
NNTP-Posting-Host: 207.175.226.26
Message-ID: <3e7cc472$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1048364146 207.175.226.26 (22 Mar 2003 12:15:46 -0800)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!news-out.visi.com!petbe.visi.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail