Mega Code Archive

 
Categories / ASP.Net / Development
 

Lock Application

<%@ Page %> <script language="C#" runat="server">   private void Page_Load(object sender, System.EventArgs e)   {     Application.Lock();     Application["ServerName"]="WebFarm1";     Application.UnLock();     MyLabel.Text=Application["ServerName"].ToString();   } </script> <html>   <body>     <form id="form1" method="post" runat="server">     <asp:Label ID="MyLabel" Runat="server"></asp:Label>      </form>   </body> </html>