c# - Set value in app.config file to null -


i'm updating app.config value during runtime, want update value null value far empty string. still want able set empty string purpose, how value return null?

try remove key, if remove value null.

var val = system.configuration.configurationmanager.appsettings["key"] 

you can remove key in code

 configuration config = configurationmanager.openexeconfiguration(configurationuserlevel.none);  config.appsettings.settings.remove("key"); 

Comments

Popular posts from this blog

javascript - WinJS appendTextAsync producing scheduler errors -

minify - Minimizing css files -

Sockets with kotlin -