Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SET DEFAULT question
Message
From
20/08/2001 13:03:38
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00546287
Message ID:
00546296
Views:
18
This message has been marked as the solution to the initial question of the thread.
>Don't ask why, but my app has never had a SET DEFAULT. Do most applications have a SET DEFAULT? Now for the first time in 3 years it has caused a problem with creating a MKDIR that only specifies the directory name and not the complete path. All the clients have a shortcut on their desktop to the app and that is how they execute it, so the MKDIR creates the directory on their desktop. I want the directory in the app folder.
>
>I have added the following lines of code in my MAIN.PRG, but the MKDIR is still created on the desktop. First, how can I tell what is the value of SET DEFAULT? Second, what is it that I am doing wrong to set the default to the folder that contained the application?
>
>sys_default = sys(5) + curdir()
>set default to (sys_default)
>
>Thanks
>
>Brenda

Brenda,
No not all apps have a set default.
To get default :
lcDefault = set('default')
or :
lcDefault = sys(5)+curdir() && Working dir

You're setting default back to where it was (probably nothing specified as startupdir in shcut). Try :

set default to (justpath(sys(16,1))

Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform