Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Default directory Issue

Status
Not open for further replies.

jspellman

Programmer
Aug 18, 2001
23
US
I am currently working on an application. I have seen the HOME() function used in the microsoft samples. When I install my application on a new computer how to I reference the different drives when creating reports or running forms. For example. I have a form I run from the menu. I call it by using the following.

DO FORM C:\FOLDER NAME\FORMS\FORM1.SCX

I want the folder name and location to be static. However when the directory changes my application does not. Is there a fix for the "C:\" problem?

Thanks
 
If your forms are included in the exe you do not need to reference the location. with that said.

PUBLIC cDataDir, cProgDir

location of were the program started. this is handy incase during the install the user changed the default location
cProgDir = SYS(5)+SYS(2003)

since I have a default layout of sub directories under the program folder, i set the data location
cDataDir = "&cProgDir.\Data"

set the
set default to &cDataDir

if you have files in locations you can assign them to vars then use it by adding it to the open command or changing directory or set default Attitude is Everything
 
Danceman,

Forms included in the .exe. Does this mean when I build the EXE. I am kind of new to this.

Thanks
 
when a file is included in the project and builted into the exe you do not need to reference the file location. any file that is included in exe does not need to be installed on users system.

Each choice you make as to exclude or include a file dependson your needs to conform to application design. Attitude is Everything
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top