web.config in asp.net -


I want to give the username, password, and API's value in web.config that is coming from the database. Set username, password, APIkey, which is to be set in web.config

  Private Zero UpdateConfig (string strkey, string strValue) {configuration objConfig = WebConfigurationManager.OpenWebConfiguration ("~"); AppSettingsSection objAppsettings = (AppSettingsSection) objConfig.GetSection ("appSettings"); If (objAppsettings! = Null) {objAppsettings.Settings [strkey] .Value = strValue; ObjConfig.Save (); }}  

But every time you update the web.config file, your application will restart the domain, so updating the web is not often configured.

View Pls:


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -