web 2.0

ASP Application.Unlock() - Application Object

ASP Application.Unlock() - Application Object Unlocks access to an Http ApplicationState variable to facilitate access synchronization.

ShotDev Focus:

- Application.Unlock()

Example

global.asa


<script language="VBScript" runat="Server">
Sub Application_OnStart
Application("OnlineNow") = 0
Application("Msg") = "Welcome to ShotDev.Com"
End Sub

Sub Session_OnStart
Application.Lock
Application("OnlineNow") = Application("OnlineNow")+1
Application.UnLock
End Sub

Sub Session_OnEnd
Application.Lock
Application("OnlineNow") = Application("OnlineNow")-1
Application.UnLock
End Sub
</script>

asp_application_unlock.asp


<% Option Explicit %>
<html>
<head>
<title>ShotDev.Com Tutorial</title>
</head>
<body>
<%
Response.write "Online Now : " & Application("OnlineNow")
%>
</body>
</html>

Create a asp file and save to path root-path/myasp/

Run

http://localhost/myasp/asp_application_unlock.asp

Screenshot

ASP & Application.Unlock()

.

.

.

Download this script.

Download

1 Star2 Stars3 Stars4 Stars5 Stars6 Stars7 Stars8 Stars9 Stars10 Stars (1 votes, average: 1.00 out of 10)
Loading ... Loading ...

Leave a Reply

You must be logged in to post a comment.