Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ASP pages Hang/Block

Status
Not open for further replies.

SamMac

Programmer
Oct 12, 2000
5
0
0
GB
If I run the following more than once then the later instances block until the earlier ones finish. It was my understanding that ASP was multithreaded...?
If I use the perfomance monitor then at most all I get is one ASP process executing and one in the queue

What am I missing here?

Cheers

<%@ LANGUAGE=&quot;VBSCRIPT&quot; %>
<%

Option Explicit
Response.Expires = 0
Response.Buffer = False
%>
<head>
</head>
<HTML>
<BODY>
<CENTER>
<%
Dim objConn, intCount

Response.write &quot;Begin: &quot; & FormatDateTime(Now(),vbLongTime)

' Open connection to DB
set objConn = Server.CreateObject(&quot;ADODB.Connection&quot;)
objConn.open &quot;Driver={SQL Server}; Server=CS09; Database=Harry; UID=sa; PWD=&quot;

%>
<TABLE BORDER=&quot;1&quot;>
<TR>
<TD><SPAN ID=&quot;Count&quot;>-</SPAN></TD>
</TR>
</TABLE>
<%
For intCount = 1 to 1 step -1
If (Not Response.IsClientConnected) then Exit For
%>
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
document.all(&quot;Count&quot;).innerHTML = &quot;<%=intCount%>&quot;;
</SCRIPT>
<%
objConn.Execute &quot;WAITFOR DELAY '00:00:01'&quot;, , adCmdText + adExecuteNoRecords
Next
%>
<SCRIPT LANGUAGE=&quot;JavaScript&quot;>
document.all(&quot;Count&quot;).innerHTML = &quot;0&quot;;
</SCRIPT>
<%
Response.write &quot;End: &quot; & FormatDateTime(Now(),vbLongTime)
%>
</CENTER>
</BODY>
</HTML>

[sig][/sig]
 
try adding set objConn=nothing at the end of the script. [sig]<p>nick bulka<br><a href=mailto: > </a><br>[/sig]
 
Thanks Nick, but this makes no difference [sig][/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top