app. config file
-
Hi! I am using windows applications and I am trying to create a application config file. I have created an app. config file thru add item and this is how it looks.. And from my code I am accessing the config file soemthing like this using System.Configuration; string path = ConfigurationSettings.AppSettings("FilePath"); I am getting this error: An unhandled exception of type 'System.Configuration.ConfigurationException' occurred in system.dll Only elements allowed I would appreciate any insight Thanks in advance
-
Hi! I am using windows applications and I am trying to create a application config file. I have created an app. config file thru add item and this is how it looks.. And from my code I am accessing the config file soemthing like this using System.Configuration; string path = ConfigurationSettings.AppSettings("FilePath"); I am getting this error: An unhandled exception of type 'System.Configuration.ConfigurationException' occurred in system.dll Only elements allowed I would appreciate any insight Thanks in advance
Hi, recently had the same problem. Check your config file for invalid chars. Exeption shows the near line where the error ocurs. In my case, the error stated: "line 32", error was in line 33 Use notepad++ with "show all characters" enabled to spot on the invalid char. Cheers.
Jaime Vasquez