Regarding User settings file location

R

Robert Dufour

Changing a setting in the UserSettings from within my app using code (Vs2005
vb.net) does not seem to persist changes to the myapp.exe.config file what
is the location and name of the file where the usersettings are persisted?

Is there any way to have modifications made in code to application level
settings? The my.settings in VS2005 and vb.net 2005 does not permit
application level settings to be modified in code cause the geniuses at MS
decided to make that section readonly.

Thanks for any help
 
R

Robert Schneider

Robert Dufour said:
Changing a setting in the UserSettings from within my app using code
(Vs2005 vb.net) does not seem to persist changes to the myapp.exe.config
file what is the location and name of the file where the usersettings are
persisted?

On Vista the user.config file with the user settings is somewhere in the
folder c:\users\georgewbush\AppData\Local\wargame\...\...

The read-only application settings are stored in the folder where the exe is
(wargame.exe.config).

Settings can be persist with My.Settings.Save.

Is there any way to have modifications made in code to application level
settings? The my.settings in VS2005 and vb.net 2005 does not permit
application level settings to be modified in code cause the geniuses at MS
decided to make that section readonly.

The config file for the application settings is just XML. You can change it
if you would like to. However, it is not the intention to change the
application settings. Consider several users working on a machine with their
own user accounts in Windows. If you would change the application settings
then you would change it for all users. When the users start the app next
time some of them may be surprised that something has changed even they
haven't done anything. And then user x resets the setting and we have the
next surprise.

Robert
 

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

Top