cannot find source of error

Discussion in 'Javascript' started by Middletree, Nov 24, 2004.

  1. Middletree

    Middletree Guest

    This is an ASP-built Intranet app, so I have saved off a static
    version of the page for reference, and it is located at
    http://www.middletree.net/err.htm and the page to compare it to is
    http://www.middletree.net/noerr.htm

    If you go to the first page, in my case using IE 6/WinXP, you'll see
    that it shows a js error. More important than just the error is that
    the menu is gone. On the 2nd page, the error doesn't exist.

    That second page only differs, code-wise in one small snippet of ASP
    code which falls an IF/ELSE ASP condition. Here's the code which
    builds the page with the error (which falls under the ELSE half):


    Else
    'if no history items
    if strNoRecords = "1" then
    Else
    Response.Write "<table cellpadding=0 cellspacing=0 border=1
    width=620 bgcolor="&bgcolor2&">"
    Response.Write "<tr><td colspan=3 align=center><span
    class=cellnumber>No work history items have been added for this
    ticket</span></td></tr></table>"
    End if
    End if

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

    Can anyone see what I am missing?
     
    Middletree, Nov 24, 2004
    #1
    1. Advertising

  2. On 24 Nov 2004 13:10:39 -0800, Middletree <> wrote:

    [snip]

    > Can anyone see what I am missing?


    The "error" page doesn't contain an element with the id, WorkHistory,
    which you try to access when the page loads in order to hide the DIV
    elements it contains.

    Mike

    --
    Michael Winter
    Replace ".invalid" with ".uk" to reply by e-mail.
     
    Michael Winter, Nov 24, 2004
    #2
    1. Advertising

  3. Middletree

    Lee Guest

    Middletree said:
    >
    >This is an ASP-built Intranet app, so I have saved off a static
    >version of the page for reference, and it is located at
    >http://www.middletree.net/err.htm and the page to compare it to is
    >http://www.middletree.net/noerr.htm
    >
    >If you go to the first page, in my case using IE 6/WinXP, you'll see
    >that it shows a js error. More important than just the error is that
    >the menu is gone. On the 2nd page, the error doesn't exist.
    >
    >That second page only differs, code-wise in one small snippet of ASP
    >code which falls an IF/ELSE ASP condition. Here's the code which
    >builds the page with the error (which falls under the ELSE half):
    >
    >
    >Else
    > 'if no history items
    > if strNoRecords = "1" then
    > Else
    > Response.Write "<table cellpadding=0 cellspacing=0 border=1
    >width=620 bgcolor="&bgcolor2&">"
    > Response.Write "<tr><td colspan=3 align=center><span
    >class=cellnumber>No work history items have been added for this
    >ticket</span></td></tr></table>"
    > End if
    >End if
    >
    >-----------------------------------
    >
    >Can anyone see what I am missing?


    If there is no work history, in addition to writing that message, you
    need to avoid writing the onload handler that tries to hide the work history.
     
    Lee, Nov 24, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Liber Almeida
    Replies:
    2
    Views:
    13,118
    Daisy
    Sep 3, 2003
  2. news.microsoft.com
    Replies:
    4
    Views:
    5,004
    =?Utf-8?B?Q2hpbm1heQ==?=
    Jan 10, 2005
  3. Wybo Dekker
    Replies:
    1
    Views:
    387
    Yukihiro Matsumoto
    Nov 15, 2005
  4. vdvorkin
    Replies:
    0
    Views:
    433
    vdvorkin
    Feb 10, 2011
  5. vdvorkin
    Replies:
    3
    Views:
    845
    vdvorkin
    Feb 14, 2011
Loading...

Share This Page