Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 3 of 3 total
Thread Where should the EDB files be stored on a client machine (Win7/Win8 UAC) ?
Tue, Jul 29 2014 2:00 PMPermanent Link

Barry

Is there any documentation concerning where the EDB files and application files should be placed on a client machine, because of UAC for Win7/Win8? Unfortunately not every user is running as Administrator.

Has anyone come up with a working set of directories where the following files should go?
(Assuming the application is run from a limited user account)

Client Server:
-----------------
1) The EDBSrvr.exe and EDBSrvr.ini.

2) The EDBConfig.* files

3) The database files: *.EDBTbl, *.EDBCat etc.

4) The Delphi application: MyProject.Exe

5) Stores files (for backup or replication)

6) Other Files? (Did I leave any files out?)

7) Do any of the above directory names need to be changed when dealing with non-C/S EDB database?

Can you provide the full directory path for each number listed above?

I'd like to get your feedback as to what works for you and what doesn't.
So feel free to jump in with both feet. Smile

TIA
Barry
Tue, Jul 29 2014 3:06 PMPermanent Link

Walter Matte

Tactical Business Corporation


Barry ... I don't have the answer, but this has some useful info....

http://capecodgunny.blogspot.ca/2014/07/choose-right-folder-for-your.html


Walter
Thu, Jul 31 2014 4:33 PMPermanent Link

Barry

Walter,

Thanks for the link. Gunny did a good job listing many of the available directories. His software works on XP and WIn7 (I did not test it on WIn8). He used CSIDL which is now deprecated for Win8 (Win7?).

I recommend everyone who is interested in Windows directories to go to Gunny's link that Walter provided and build the Delphi app that he wrote. It takes 5 minutes. You will get a list of couple dozen Windows directories and what they are suppose to be used for.

Gunny has a Google thread at https://plus.google.com/105522328114529031567/posts/Q8go8eWRAfz which tries to ascertain which directories should be use for applications and databases.

Here is what I've sorted out (or not!)


--------- Database Location --------

Many users on the thread recommended to put the data under
DB1)  C:\AppData\<CompanyName>\<AppName>,  CSIDL_COMMON_APPDATA.
That is the likely choice for either a local EDB database or C/S. (Provided it will be shared by all users).

-------- Application Location --------

The application (.exe) is a different matter. There are 3 choices from what I can see:
A1) C:\Program Files\<CompanyName>\<AppName> =  CSIDL_PROGRAM_FILES
A2) C:\<CompanyName>\AppData\Roaming<AppName> = Custom Directory
A3) C:\Program Files\Common Files\<CompanyName>\<AppName> = CSIDL_PROGRAM_FILES_COMMON

#A1 is the likely choice for all users.
#A2 may cause problems for companies because it is not a standard program directory
#A3 is for DLL's or .exe's that may be shared by more than one application

------- .INI File Location ---------

We also have the <AppName>.ini file or other permanent writeable files to worry about. They can't go in the program directory because most users will not have write access to it. And with a client machine, if there is an  .ini file, it will be stored locally.

So that leaves:
I1) CSIDL_PROGRAM_FILES_COMMON (Same as A3)
C:\Program Files\CommonFiles\<CompanyName>\<AppName>

I2) CSIDL_COMMON_APPDATA
C:\ProgramData\<CompanyName>\<AppName>   (Same as DB1)

I3) or for single user non-roaming (CSIDL_LOCAL_APPDATA):
C:\Users\<UserName>\AppData\Local\<CompanyName>\<AppName>

I4) or portable app (CSIDL_APPDATA):
C:\Users\<UserName>\AppData\Roaming\<CompanyName>\<AppName>

So there you have it. Installing an application in Win7/Win8 can turn into quite a problem if it is not installed in the proper directories (because of UAC), which is what I'm trying to avoid.

Does anyone have any recommendations (from experience) as to which folders will work for the majority of users for a C/S app? Will the same directories work for a LAN or local app? (I prefer to have the same directory structure for all 3 types of apps if possible).

TIA
Barry

http://msdn.microsoft.com/en-us/library/windows/desktop/bb762494%28v=vs.85%29.aspx
Image