标签:c style class blog code java
<?xml version="1.0" encoding="utf-8" ?> <configuration> <appSettings> <add key="Number0" value="9759436"/> <add key="Number1" value="9759437"/> <add key="Number2" value="9759438"/> <add key="Number3" value="9759439"/> </appSettings> <startup> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" /> </startup> </configuration>
private void Button_Click_1(object sender, RoutedEventArgs e) { int i = int.Parse(ConfigurationManager.AppSettings["Number2"]); this.txtMsg.Text = i.ToString(); }
Configuration cfa = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel.None); cfa.AppSettings.Settings["Number2"].Value = "65434"; cfa.Save();
ConfigurationManager,布布扣,bubuko.com
标签:c style class blog code java
原文地址:http://www.cnblogs.com/infly123/p/3759611.html