List Box is Hanging Up

Results 1 to 2 of 2

Thread: List Box is Hanging Up

  1. #1
    Join Date
    Dec 1969

    Default List Box is Hanging Up

    I have a list box that is populated from an access database. When you go to the page the first time, the list box will populate correctly, but if someone else hits the page within a few seconds or you refresh, it will not populate the list box. No errors, it just creates a blank list box. I am closing the database connection and setting it equal to nothing each time. And if you wait about 30 seconds or so, it will work again. Any ideas? <BR>The page in question is at <BR><BR>Here is the code I am using to populate the list box. <BR><BR>&#060;% <BR>Dim objConn <BR>Set objConn = Server.CreateObject("ADODB.Connection") <BR>objConn.ConnectionString="DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("mission2000dbTico.mdb") <BR>objConn.Open <BR><BR>Dim objStateRS <BR>Dim strState <BR>Set objStateRS = Server.CreateObject("ADODB.Recordset") <BR>objStateRS.Open "States", objConn, , , adCmdTable <BR>strState = Request.QueryString("State") <BR>Do While Not objStateRS.EOF <BR>If objStateRS("Value") = strState Then <BR>Response.Write "&#060;Option Value=" & objStateRS("Value") & " SELECTED&#062;" & objStateRS("State") & "&#060;/OPTION&#062;" <BR>Else <BR>Response.Write "&#060;Option Value=" & objStateRS("Value") & "&#062;" & objStateRS("State") & "&#060;/OPTION&#062;" <BR>End If <BR>objStateRS.MoveNext <BR>Loop <BR>objStateRS.Close <BR>Set objRS = Nothing <BR>objConn.Close <BR>Set objConn = Nothing <BR>%&#062;

  2. #2
    Join Date
    Dec 1969

    Default RE: List Box is Hanging Up

    Hmm<BR><BR>Maybe you should look into putting those values into an application variable, especially if they don&#039;t change very often,<BR><BR>my guess is that your database can&#039;t keep up. <BR>&#060;just a guess though&#062;

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts