473,326 Members | 2,108 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

"Correct" place to stopre data files?

I've been somewhat confused about what the "proper" place is to store
data files (like file based databases) for my applications.

With all the different "special" folders available, which is the correct
one for databases that get updated every time a user runs the
application? I need to make sure that Windows 98 users can use my
software as well, but I also need make sure that the data file is always
accessible at a consistent location in my software.

Any tips appreciated!

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com
Nov 21 '05 #1
13 1541
Mitchel,

Although not correct is the application.startuppath as well not a bad place.
We see it Microsoft do with Visual Studio Net.

I hope this helps,

Cor
Nov 21 '05 #2
"Mitchell Vincent" <mv******@newsgroup.nospam> schrieb:
You should be able to write to the Application.UserAppDataPath folder
safely.


Is that accessible to "all users"? I always install my software so that
any user on the system can access it.


Use
'Environment.GetFolderPath(Environment.SpecialFold er.CommonApplicationData)'
instead.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #3
You should be able to write to the Application.UserAppDataPath folder
safely.

"Mitchell Vincent" <mv******@newsgroup.nospam> wrote in message
news:eS*************@TK2MSFTNGP10.phx.gbl...
I've been somewhat confused about what the "proper" place is to store data
files (like file based databases) for my applications.

With all the different "special" folders available, which is the correct
one for databases that get updated every time a user runs the application?
I need to make sure that Windows 98 users can use my software as well, but
I also need make sure that the data file is always accessible at a
consistent location in my software.

Any tips appreciated!

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com

Nov 21 '05 #4
Marina wrote:
You should be able to write to the Application.UserAppDataPath folder
safely.


Is that accessible to "all users"? I always install my software so that
any user on the system can access it.

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com
Nov 21 '05 #5
Yes, this will be stored in each users's data directory. Try it out and run
some quick test to see if it meets your needs.

"Mitchell Vincent" <mv******@newsgroup.nospam> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Marina wrote:
You should be able to write to the Application.UserAppDataPath folder
safely.


Is that accessible to "all users"? I always install my software so that
any user on the system can access it.

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com

Nov 21 '05 #6
Herfried K. Wagner [MVP] wrote:
Use
'Environment.GetFolderPath(Environment.SpecialFold er.CommonApplicationData)'
instead.


I assume it works with Windows 98, but where is the actual directory on
a 98 box? I don't have one to test, or I would.

Thanks!

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com
Nov 21 '05 #7
Mitchel,

Although not correct is the application.startuppath as well not a bad place.
We see it Microsoft do with Visual Studio Net.

I hope this helps,

Cor
Nov 21 '05 #8
Cor Ligthert [MVP] wrote:
Mitchel,

Although not correct is the application.startuppath as well not a bad place.
We see it Microsoft do with Visual Studio Net.

I hope this helps,

Cor


That's what I do now, but I was thinking that in some multi-user setups
the user might not be able to write to the Program Files directory, so
all the writes to the database *could* fail in theory.

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com
Nov 21 '05 #9
"Mitchell Vincent" <mv******@newsgroup.nospam> schrieb:
You should be able to write to the Application.UserAppDataPath folder
safely.


Is that accessible to "all users"? I always install my software so that
any user on the system can access it.


Use
'Environment.GetFolderPath(Environment.SpecialFold er.CommonApplicationData)'
instead.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #10
Herfried K. Wagner [MVP] wrote:
Use
'Environment.GetFolderPath(Environment.SpecialFold er.CommonApplicationData)'
instead.


I assume it works with Windows 98, but where is the actual directory on
a 98 box? I don't have one to test, or I would.

Thanks!

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com
Nov 21 '05 #11
Cor Ligthert [MVP] wrote:
Mitchel,

Although not correct is the application.startuppath as well not a bad place.
We see it Microsoft do with Visual Studio Net.

I hope this helps,

Cor


That's what I do now, but I was thinking that in some multi-user setups
the user might not be able to write to the Program Files directory, so
all the writes to the database *could* fail in theory.

--
- Mitchell Vincent
- kBilling - Invoices Made Easy!
- http://www.k-billing.com
Nov 21 '05 #12
Hi

I think in win98, it should be the directory similar with below
CSIDL_COMMON_APPDATA,CommonApplicationData
C:\WINDOWS\All Users\Application Data

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 21 '05 #13
Hi

I think in win98, it should be the directory similar with below
CSIDL_COMMON_APPDATA,CommonApplicationData
C:\WINDOWS\All Users\Application Data

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 21 '05 #14

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: CLEAR-RCIC | last post by:
Hello All, I wrote a .dll that programatically maps two network drives and copies files from one drive to the other. The .dll works fine when using an .exe to call the .dll. When I call the...
5
by: Alf P. Steinbach | last post by:
Thanks to a new version of OpenOffice that produces acceptable (although not yet perfect) PDF, and numerous requests for PDF format, I've now made chapter 2.1 available in PDF format -- e.g., use...
53
by: Alf P. Steinbach | last post by:
So, I got the itch to write something more... I apologize for not doing more on the attempted "Correct C++ Tutorial" earlier, but there were reasons. This is an UNFINISHED and RAW document,...
3
by: Mitchell Vincent | last post by:
I've been somewhat confused about what the "proper" place is to store data files (like file based databases) for my applications. With all the different "special" folders available, which is the...
50
by: Shadow Lynx | last post by:
Consider this simple HTML: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 STRICT//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head>...
4
by: metaperl | last post by:
I work at a place which is currently running SQL 2000, but they are planning to migrate to 2k5. I was thinking that this is the perfect opportunity to fix all the weaknesses we have had in our data...
4
by: chaitu | last post by:
Hi guys, I've written a parallel build program (in Perl) that takes a pre-computed dependency tree of many projects in 2 visual studio .net 2003 solution (.sln) files here at my company, and...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.