Changing the location of a *.settings file

  • Thread starter Thread starter Jamie McQuay
  • Start date Start date
J

Jamie McQuay

Does any one know if it is possible to set the location of a settings
file? I want to use separate settings files for each user and will
need to change the location.

[using C# with framework 2.0]

Thanks,

Jamie
 
Jamie McQuay said:
Does any one know if it is possible to set the location of a settings
file? I want to use separate settings files for each user and will
need to change the location.

When you save your settings from within the program, the settings file
(user.config) is placed in Documents and Settings/<user name>/Local
Settings/..., so there's already a unique settings file for each user.

Were you looking for something different? (e.g. if your "users" don't
correspond to the logged-in user running the application).

-cd
 
When you save your settings from within the program, the settings file
(user.config) is placed in Documents and Settings/<user name>/Local
Settings/..., so there's already a unique settings file for each user.

That would be the idea way but the "users" only exsist w.r.t the
application
Were you looking for something different? (e.g. if your "users" don't
correspond to the logged-in user running the application).
yes, that's my situation.

Regards,

Jamie
 
Jamie said:
That would be the idea way but the "users" only exsist w.r.t the
application

yes, that's my situation.

Sadly, unless there's a bit of secret sauce that I haven't discovered,
you're out of luck. The settings facility is quite hard-wired as to the
names and locations of the files that it opens. You can of course build
your own settings facility that stores the settings in a file of your
choosing, but you won't be able to make use of the "settings" support in the
IDE going that route.

-cd
 
Sadly, unless there's a bit of secret sauce that I haven't discovered,
you're out of luck. The settings facility is quite hard-wired as to the
names and locations of the files that it opens. You can of course build
your own settings facility that stores the settings in a file of your
choosing, but you won't be able to make use of the "settings" support in the
IDE going that route.

thanks carl,

I've been using my own system and was trying to get away from it.

Regards,

Jamie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top