Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here


Where to Locate data file for application on install?

Where to Locate data file for application on install?

Where to Locate data file for application on install?

Hi Folks

Hoping for a little advice. I have a VB.NET 2008 application I've been working on for a number of years, and finally it's almost ready to be released. I'm trying to figure out, though, where I can place my data file where I can have both read and write access to it and where it won't be wiped away by an over-zealous cleaner program.

In the old days (XP) I would have just located the file in the application folder along with the executable. But it seems now that files located there no longer have write access which pretty much negates the use of that location.

So what is left to me? I have been doing a little research, I found some info on the ProgramData folder but also found several statements saying not to use this folder. I looked into the AppData folder options but apparently these aren't meant as a permanent location, and data in them can be swept out by cleaner programs.

So I ask, what would you do? Where is a safe place I can place my data files where it will have read and write rights?



RE: Where to Locate data file for application on install?

%APPDATA% is the default location for data that is user specific

%PROGRAMDATA% is default location for data that is global (same for all users)

Configuration data should be kept in the registry HKLM for global, HKCU for user specific.


Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close