🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: be.comp.programming
Article #5553

Path applicatie Visual Basic

#5553
From: Tim
Date: Fri, 02 May 2003 04:55
16 lines
1752 bytes
Bestaat er een functie of mogelijkheid in Visual Basic (VB6, geen .NET) dat
de applicatie z'n eigen locatie kan achterhalen?

Probleemstelling is volgende:
Stel:
    Path applicatie: D:\VB\MediaSys\MediaSys.exe
    Path database D:\VB\MediaSys\Database\MediaSys.mdb
    Path snelkoppeling naar MediaSys.exe: C:\Test\MediaSys.lnk
In m'n code verwijs ik relatie naar die database, dus met
"Database\MediaSys.mdb"
Indien ik de applicatie start via die snelkoppeling dan vindt de database
echter niet, omdat hij dan waarschijnlijk zoekt op locatie
C:\Test\Database\MediaSys.mdb.

Daarom ben ik op zoek naar een functie of een manier om in MediaSys.exe te
zeggen dat z'n pad D:\VB\MediaSys\ of D:\VB\MediaSys\MediaSys.exe is.
Technical Details
Message-ID: <0Tmsa.70842$t_2.6538@afrodite.telenet-ops.be>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!news.maxwell.syr.edu!nntp.abs.net!news-out.cwix.com!newsfeed.cwix.com!ossa.telenet-ops.be!afrodite.telenet-ops.be.POSTED!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: DUTCH,ASCII-7-bit
X-Google-Thread: fcea4,9d789217a70f8c7f,start
X-Google-Attributes: gidfcea4,public
X-Google-ArrivalTime: 2003-05-01 21:56:09 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!news.maxwell.syr.edu!nntp.abs.net!news-out.cwix.com!newsfeed.cwix.com!ossa.telenet-ops.be!afrodite.telenet-ops.be.POSTED!not-for-mail
From: "Tim" <tim.p@pandora.be>
Newsgroups: be.comp.programming
Subject: Path applicatie Visual Basic
Lines: 18
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
Message-ID: <0Tmsa.70842$t_2.6538@afrodite.telenet-ops.be>
Date: Fri, 02 May 2003 04:55:24 GMT
NNTP-Posting-Host: 213.224.115.53
X-Complaints-To: abuse@telenet.be
X-Trace: afrodite.telenet-ops.be 1051851324 213.224.115.53 (Fri, 02 May 2003 06:55:24 MET DST)
NNTP-Posting-Date: Fri, 02 May 2003 06:55:24 MET DST
Organization: Telenet Internet