Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Find path for a file
Message
From
11/07/2001 11:21:13
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00529148
Message ID:
00529179
Views:
18
Fabian,
You can use FULLPATH(). This works if VFP can find the file (SET PATH). Beware that FULLPATH() may return a filename that doesn't exist. For this reason make sure you check that the file exists:
lcFullPath = FULLPATH("VFP6.EXE")
IF FILE(lcFullPath)
   *-- file exists and we've got the full path
ELSE
   *-- VFP couldn't find the file, either because it doesn't
   *-- exist or because it's not in VFP's path
ENDIF
>mmhh... justPath() returns the path of a given pathname/filename... doesn´t it?
>
>what I want is to retrieve the path of a file that I don´t know where it is...
>i.e. : find Prog.exe file... maybe it's in Program Files\Prog\Prog.exe or maybe in Archivos de Programa\Prog\Prog.exe
>
>so I'd like something like path = findpath("Prog.exe")
Daniel
Previous
Reply
Map
View

Click here to load this message in the networking platform