Developer technologies | .NET | Other
Microsoft Technologies based on the .NET software framework. Miscellaneous topics that do not fit into specific categories.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I'm using Visual Code and I want set values in the appsettings file. Then retrieve them using Configuration Manager - see below - I'm getting following error:
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object. at Program.Main() in C:\Chaumette\Development\IntuneTokenApp\Program.cs:line 11
Visual Code is new to me- I'm not sure why it's not finding the value. I manually added appSettings.config - Is there any special configuration needed?
var applicationId = ConfigurationManager.AppSettings["appId"].ToString();