Too much frustrated with this problem... :-(
Winforms, C# 2.0, VS 2010
While developing, I just try to access to a setting value in Settings.setting file. For example:
string foo = MyProject.Properties.Settings.Default.InstallerLogFile_Path
As expected, it works.
But while deploying my .exe file at any other machine, I'm getting an Configuration system failed to initialize
exception. Inner exception says: Could not find a part of the path C:\Documents and Settings\...\user.config
.
In my Settings.settings file I have a few application-scoped strings and one user-scoped WebService URL. I need it as user-scoped since URL value may change at runtime.
EDIT: I have just created a test application that simply raises a MessageBox with one application scoped string value and one user scoped string value. It works with no need of saving the settings Settings.Default.Save()
nor some other "extra" actions... this is driving me crazy :(
Any help will be very much appreciated.
On your other machine if you see a file called YourApplicationName.vshost.exe and YourApplicationName.vshost.exe.config delete them and see if the error still persists.