Articles → .NET → Making Application Offline

Making Application Offline







Picture showing the error message when the application is offline
Click to Enlarge





  1. Disable httpRuntime. Open web.config file and add a property called enable = "false" in tag in web.config file.


  2. <httpRuntime enable="false"/>


  3. Add a file "App_Offline.htm" in the project. A HTML page which gives some information to the end user.


Picture showing the custom page displayed when the application is offline
Click to Enlarge


Important →


  1. If the size of App_Offline.htm is greater than 1 MB then ASP.NET runtime will not return App_Offline.htm page.
  2. If the size of App_Offline.htm is lesser than 512 bytes then an error message of internet explorer is shown.



Posted By  -  Karan Gupta
 
Posted On  -  Sunday, August 15, 2010

Query/Feedback


Your Email Id
 
Subject
 
Query/FeedbackCharacters remaining 250