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

neo4j - finding mutual friends in a cypher statement starting with three or more persons -

minify - Minimizing css files -

php - How to remove letter in front of the word laravel -