View Single Post
  #6 (permalink)  
Old February 19th, 2009, 10:20 AM
louisa68 louisa68 is offline
Authorized User
Join Date: Feb 2009
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts

Originally Posted by Imar View Post
Hi there,

You may want to take a look here:

It's a nice introduction in working with the configuration API to write to config files.

Hope this helps,

Hi, I looked at this and it said "Another caveat is that the ASP.NET runtime watches web.config and will restart the web application when a change occurs. Specifically, the runtime will create a new instance of your application inside of a new AppDomain anytime you write to web.config. A restart can have a performance impact, so writing to web.config should not occur often." but my website doesn't restart as if it did it would pick up my changes and not show the setup page again,
I have the following code in after the changes are saved to the web config but they don't seem to help.
System.Configuration.ConfigurationManager.RefreshS ection(.ConnectionStrings.SectionInformation.Name)
System.Configuration.ConfigurationManager.RefreshS ection(.AppSettings.SectionInformation.Name)

If I exist & go back into the site then it doesn't show the setup page again as the changes are being saved correctly, I just want to not have to do it manually, any other ideas out there?