I know this is an old problem but every few months I get caught by it. The problem is that ConfigurationManager that is used to get settings from the app.config/web.config file is not available.
The solution is simple. Add reference to the dll: System.Configuration.
string settings = ConfigurationManager.AppSettings["SomeSettings"];