Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 12 of 12
  1. #1
    New Coder
    Join Date
    Feb 2012
    Posts
    14
    Thanks
    11
    Thanked 0 Times in 0 Posts

    Microsoft VBScript runtime error '800a0006' Overflow: '[number: 32768]'

    I got the error when i place mutiple do while loops in the result asp page, i had created so far 68 Do While Loops but now when i create the 69 Do while Loop, it given the error Microsoft VBScript runtime error '800a0006' Overflow: '[number: 32768]'

    Please can anyone help....it's really urgent

    Thanks in Advance
    Syed

  • #2
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,441
    Thanks
    76
    Thanked 4,372 Times in 4,337 Posts
    You must be using the CINT( ) function somewhere in there. CINT() is limited to SHORT integers, in the range of -32768 to +32767. Just use CLNG( ) instead.

    If that's not the problem, you will have to show some code.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    Sydhussain2010 (03-01-2012)

  • #3
    New Coder
    Join Date
    Feb 2012
    Posts
    14
    Thanks
    11
    Thanked 0 Times in 0 Posts

    Please check the code which i used in my report

    The following loop i have started from Recordset1middle1 to Recordset1middle68 and its working fine till Recordset1middle68 but when i copy and paste and change the all Recordset1middle68 to Recordset1middle69 it give the error Microsoft VBScript runtime error '800a0006' Overflow: '[number: 32768]'

    ------------------------------------------------------------------
    Multiple Loops used from Recordset1middle1 to Recordset1middle68
    ------------------------------------------------------------------
    <table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
    <% Do While not Recordset1middle68.eof %>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("a")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("a")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("b")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("b")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("c")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("c")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("d")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("d")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("e")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("e")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("f")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("f")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("g")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("g")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("h")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("h")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <tr bgcolor="<%=bgColor%>">
    <%If Recordset1middle68("i")<>"0" then %>
    <td height="25" bgColor="FBAEDA" class="bfont"><p align="center" class="insett1"><%=Recordset1middle68("i")%></td>
    <%else%>
    <td width="400" height="25" class="bfont"><p align="center" class="insett1"></td>
    <%End if%>
    </tr>
    <% Recordset1middle68.MoveNext %>
    <%
    if bgColor="efefef" then
    bgColor="F0E3C3"
    else
    bgColor="efefef"
    end if
    %>
    <% Loop %>
    </table>

  • #4
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,441
    Thanks
    76
    Thanked 4,372 Times in 4,337 Posts
    And WHAT LINE does it give that error on.

    I have to say that I will bet that you are going about this problem completely wrong.

    I have coded truly THOUSANDS of ASP pages in the last 12 years, and NOT ONCE have I needed more than maybe five or six or so recordsets on one page.

    Having 68 or 69 recordsets means your page is going to be really slow.

    On top of that, your repetitive coding is simple not needed, at all. You are making it all way too much code and too hard.

    Example of just ONE MINOR improvement to your code:
    Code:
    <table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
    <% 
    fieldLetters = "abcdefghi"
    Do While not Recordset1middle68.eof 
        For f = 1 To Len(fieldLetters)
            value = Recordset1middle68( Mid(fieldLetters,f,1) )
    %>
            <tr bgcolor="<%=bgColor%>">
    <%
            If value <> 0 Then ' surely you should be comparing to number 0, not string "0"
    %>
                <td height="25" bgColor="FBAEDA" class="bfont">
                    <p align="center" class="insett1"><%=value%></p></td>
             </tr>
    <%      else%>
               <td width="400" height="25" class="bfont"><p align="center" class="insett1">&nbsp;</p></td>
             </tr>
    <%
            End if
        Next ' next f, so next letter
        if bgColor="efefef" then bgColor="F0E3C3" else bgColor="efefef"
    Loop
    %>
    </table>
    And almost surely I could similarly do away with all your recordsets except one.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    Sydhussain2010 (03-01-2012)

  • #5
    New Coder
    Join Date
    Feb 2012
    Posts
    14
    Thanks
    11
    Thanked 0 Times in 0 Posts

    Microsoft VBScript runtime error '800a000d' Type mismatch

    Microsoft VBScript runtime error '800a000d' Type mismatch error appears on the following field:-
    <%
    If value <> 0 Then ' surely you should be comparing to number 0, not string "0"
    %>

  • #6
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,441
    Thanks
    76
    Thanked 4,372 Times in 4,337 Posts
    So what *IS* the data type of all your a,b,c,d... field in the table you are accessing?

    Is it INT? VARCHAR? What?

    You can try using
    Code:
        If value <> "0" Then
    But I suspect that then you will be back to your 32768 error.

    You just are giving me *NO* information to work with.

    I need to know what kinds of data is in those fields. I need to know WHY you are using 68 or 69 different recordsets. I need.. Well, I can't help you when I am blind.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    Sydhussain2010 (03-02-2012)

  • #7
    New Coder
    Join Date
    Feb 2012
    Posts
    14
    Thanks
    11
    Thanked 0 Times in 0 Posts

    the datatype of a,b,c,d,e,f....is a numeric type

    Hi,

    the datatype of a,b,c,d,e,f....is a numeric type consist of 95 records and i count the all values for 73 different users thats why i used 73 do while loops...First Loop - do while no recordset1.eof ----Last Loop - do while no recordset73.eof

    thanks

  • #8
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,441
    Thanks
    76
    Thanked 4,372 Times in 4,337 Posts
    Pardon me, but that is HORRIBLE coding.

    There's no reason to have more than *ONE* recordset for all of that.

    Anyway... WHAT numeric type? If it is DECIMAL or MONEY, then that is the problem.

    Try using
    Code:
        If CDBL(value) <> 0 Then
    VBScript can *NOT* handle any numeric data types except INT and FLOAT/DOUBLE. So you must convert from other types to DOUBLE using CDBL to be safe.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    Sydhussain2010 (03-02-2012)

  • #9
    New Coder
    Join Date
    Feb 2012
    Posts
    14
    Thanks
    11
    Thanked 0 Times in 0 Posts

    Response object error 'ASP 0251 : 80004005'

    After applying If CDBL(value) <> 0 Then --- got the following error

    Response object error 'ASP 0251 : 80004005'

    Response Buffer Limit Exceeded

    /employee_report.asp, line 0

    Execution of the ASP page caused the Response Buffer to exceed its configured limit
    ------------------

    the datatype of the fields are numeric and length is 9

    --------------------------------------------------------

    Beside that can you kindly tell me how i can increase the file upload limit in IIS7 in windows server 2008

  • #10
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,441
    Thanks
    76
    Thanked 4,372 Times in 4,337 Posts
    That's an easy fix:

    The problem is that you are dumping out so much HTML that the internal buffer that ASP uses for the Response.Write gets filled up.

    All you have to do is FLUSH the buffer from time to time.

    A very good time to do so is after EACH </table> that your write out.

    Just add in the ASP line:
    Code:
        Response.Flush
    again, do that after each </table> that you write out, whether you write it via
    Code:
    Response.Write "</table>"
    or just use HTML to write it out.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    Sydhussain2010 (03-04-2012)

  • #11
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,441
    Thanks
    76
    Thanked 4,372 Times in 4,337 Posts
    For example, in the code I showed you would do it here:
    Code:
        ... other code ...
    <%
            End if
        Next ' next f, so next letter
        if bgColor="efefef" then bgColor="F0E3C3" else bgColor="efefef"
    Loop
    %>
    </table>
    <% Response.Flush %>
    ...
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • Users who have thanked Old Pedant for this post:

    Sydhussain2010 (03-04-2012)

  • #12
    New Coder
    Join Date
    Feb 2012
    Posts
    14
    Thanks
    11
    Thanked 0 Times in 0 Posts

    this is an unresolve matter, we will fix it later..

    Kindly for the time being we postpone this issue, meanwhile i have another issue if you please guide me how to increase the upload file limit size in IIS 7 , till the file size 400 KB, the asp application successfully uploaded the file but when it reach 500 KB it will not allowed to upload, but in the same time when this upload application running in my PC IIS 6, it was working excellent and can upload any file size.

    Thanks a lot for your Kind Help
    Syed


  •  

    Posting Permissions

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