asp.net.ph

Application.UnLock Method

System.Web Namespace   HttpApplicationState Class


Unlocks access to an HttpApplicationState variable to facilitate access synchronization.

[ VB ]
Public Sub UnLock ( ) 

[ C# ]
public void UnLock ( );

[ C++ ]
public: void UnLock ( );

[ JScript ]
public function UnLock ( );

Example

The following example uses Lock ( ) and UnLock ( ) to prevent other sessions from changing the value of an application variable until after the local session has changed them.

Application.Lock ( );
Application [ "myPageHits" ] = Convert.ToInt32 ( Application [ "myPageHits" ] ) + 1;
Application.UnLock ( );
  C# VB JScript

See Also

HttpApplicationState Members Skip Navigation Links




Home
Suggested Reading


Previous page Back to top Next page

© 2000-2010 Rey Nuñez All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note

You can help support asp.net.ph