#1
  1. No Profile Picture
    Contributing User
    ASP Discoverer (100 - 499 posts)

    Join Date
    Jan 2007
    Posts
    116
    Rep Power
    0

    The maximum amount of time for a script to execute was exceeded


    HI,
    i wirte SQL statment to collect information from oracel database but after 5 minutes i got the following measage
    Error Type:
    Active Server Pages, ASP 0113 (0x80004005)
    The maximum amount of time for a script to execute was exceeded. You can change this limit by specifying a new value for the property Server.ScriptTimeout or by changing the value in the IIS administration tools.

    is there something wrong with my code or what ?
    [code>

    tr>
    <td ALIGN=RIGHT NOWRAP CLASS="tdHeader">Slot Name:</td>
    <td CLASS="tdNormal">
    <%

    dim selectedSlt
    selectedSlt = request("Load7")
    Response.Write "<select name='Slot' style='width:138px' onchange=""lstchanged(4);"">"
    Set objRS4 = Server.CreateObject("ADODB.Recordset")
    strSQL4 = "SELECT SLOT_NAME, CHASSIS_NAME FROM ne.port_view WHERE CHASSIS_NAME LIKE '"&selectedChs&"%' ORDER BY SLOT_NAME"
    Set objRS4 = oracleconn.Execute(strSQL4)

    if request("Load6") = "3" then
    if selectedSlt = "" then
    Do While objRS4.EOF = false
    Response.Write "<option value='"& objRS4("CHASSIS_NAME") &"'>" & objRS4("SLOT_NAME") & "</option>" & vbCrLf
    objRS4.movenext
    Loop

    else
    Do While objRS4.EOF = false
    if selectedSlt = objRS4("CHASSIS_NAME") then
    Response.Write "<option value='"& objRS4("CHASSIS_NAME") &"' selected>" & objRS4("SLOT_NAME") & "</option>" & vbCrLf
    else
    Response.Write "<option value='"& objRS4("CHASSIS_NAME") &"'>" & objRS4("SLOT_NAME") & "</option>" & vbCrLf
    end if
    objRS4.movenext
    Loop
    end if
    end if

    %>
    </select>
    </td>
    </tr>
    [/code]
  2. #2
  3. No Profile Picture
    Contributing User
    ASP Discoverer (100 - 499 posts)

    Join Date
    Jan 2005
    Location
    Kent, UK
    Posts
    198
    Rep Power
    16
    I get this problem with fasthosts.co.uk they limit the amount of time that scripts can run for, are you using shared hosting?
  4. #3
  5. No Profile Picture
    Contributing User
    ASP Discoverer (100 - 499 posts)

    Join Date
    Jan 2007
    Posts
    116
    Rep Power
    0

    local hosting


    since i'm new in programming field all what i know that we use local hosting, what do u mean by shared hsting ?
  6. #4
  7. Contributing User
    ASP Genius (4000 - 4499 posts)

    Join Date
    Jun 2004
    Location
    Somewhere only we know...
    Posts
    4,230
    Rep Power
    1499
    Do you think your script should take a long time to run?
    That's the first thing to think about.

    You can set the script timeout by changing the value in IIS. If you go into the properties of the site and then under Home Directory....Application settings, click the configuration button.

    You can set the default script timeout in there. Or you can set the timeout on a specific script by using
    server.ScriptTimeout=1000 ' or whatever value you want to set this to.

    Hope that helps.
    My ASP.NET Blog
    I'd rather have a full bottle in front of me, than a full frontal lobotomy...
  8. #5
  9. No Profile Picture
    Contributing User
    ASP Mastermind (5000+ posts)

    Join Date
    Aug 2005
    Location
    North East, UK
    Posts
    6,191
    Rep Power
    141
    An infinite loop is a common cause for a timeout. Check any loops in your script.
  10. #6
  11. Contributing User
    ASP Genius (4000 - 4499 posts)

    Join Date
    Jun 2004
    Location
    Somewhere only we know...
    Posts
    4,230
    Rep Power
    1499
    Originally Posted by degsy
    An infinite loop is a common cause for a timeout. Check any loops in your script.
    Yep. That's what I meant by do you expect it to take a long time to run...

Similar Threads

  1. Execute Macro/Code at Specified Time
    By Arthur Bostrom in forum Microsoft Access Help
    Replies: 0
    Last Post: July 14th, 2004, 02:57 AM
  2. Display time to execute SQL query
    By mikelauff in forum ASP Development
    Replies: 0
    Last Post: May 9th, 2004, 09:21 AM
  3. summing a time
    By GaryN in forum Microsoft Access Help
    Replies: 2
    Last Post: May 7th, 2004, 01:04 PM
  4. get user date and time
    By Descenter in forum ASP Development
    Replies: 9
    Last Post: April 25th, 2004, 04:15 PM
  5. Date and time
    By thehen in forum Programming Help
    Replies: 0
    Last Post: October 16th, 2003, 02:17 AM

IMN logo majestic logo threadwatch logo seochat tools logo