KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Getting Pathname Using 4D Client
PRODUCT: 4D | VERSION: 2003 | PLATFORM: Mac & Win
Published On: July 1, 2004

Using the Structure file and Data file commands while running 4D Client only returns the structure file name and data file name. If you want to get the pathname to the location of the database structure file and data file, you can use a stored procedure that will store the pathname in a process variable, and then you can retrieve the contents of the variable using ‘Get Process Variable’ command. The sample code below performs the process:

From On Server Startup method, perform
<>MyPathStructure:=Structure file `get pathname to structure file
<>MyPathData:=Data file `get pathname to data file

From 4D Client, perform:
MyPathStructure:=""
MyPathData:=""
GET PROCESS VARIABLE (-1;<>MyPathStructure;MyPathStructure;<>MyPathData;MyPathData)