General information
Category:
Coding, syntax & commands
John
I put all my development apps in C:\APPSVFP\ ie C:\APPSVFP\App1
Then set up all the normal subdirs in each app ie data, forms, libs, progs etc
The user can install the app anywhere as long as the tables are in the \data subdir of the apps directory.
Then use something like the following in the startup program
* Set default directory to locate and save files
lcLastDefault = SYS(2003)
Set DEFAULT TO SYS(2003)+"\data"
* Store Application Data Path if required
gcDataPath = SYS(2003)+"\"
* Setup new Application Path
lcLastSetPath =SET("PATH")
Set PATH TO Forms; Menus; Progs; Reports
*Store name and path of this app
gcExeFile = FULLPATH(SYS(16,0))
* If running APP set testmode flag .T.
If UPPER(SUBSTR(gcExeFile,(LEN(gcExeFile)-2),3)) = "EXE"
gltestmode = .F.
Else
gltestmode = .T.
Endif
#INCLUDE \Include\rating.h
Set PROCEDURE TO "\progs\errors"
Set PROCEDURE TO "\progs\encoders" ADDITIVE
Hope this helps
Chris
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only