Advertisement
Guest User

Untitled

a guest
Dec 18th, 2014
146
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. Configuration config = WebConfigurationManager.OpenWebConfiguration(Request.ApplicationPath);
  2. ConnectionStringsSection sec = (ConnectionStringsSection)config.GetSection("connectionStrings");
  3. sec.ConnectionStrings["DBCS"].ConnectionString = "Data Source=GKS_004-PC;Database=hello1;User ID=123;Password=123";
  4. config.Save();
  5.  
  6.  
  7.  
  8. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement