#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2003
    Posts
    51
    Rep Power
    11

    is null or not an object error


    I am working in html/asp within VisInterDev 6.0. Everything was working fine until I moved a text box from one page to another. I took it from within a form on one page to a form on another (and made the necessary changes in the two pages).

    Here is the code that is generating the error:

    <body onload="javascript:eventreg3.distance.focus();">

    However I am using syntactically indentical code on other pages that work fine so I know the problem is not with that line.

    It appears that it is not able to find the "distance" text box, but I have been over and over the html and can't find an issue. If I take that line out (keeping the <body> of course) it doesn't generate an error but my submit button doesn't work.
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2001
    Location
    NJ
    Posts
    428
    Rep Power
    16
    Are you sure that this textbox is within a <form> tag?
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2003
    Posts
    51
    Rep Power
    11

    Thanks!!!


    So after much review I noticed that my </form> tag was not where it originally was. Not sure why that happened but you are exactly right. The object in question and the submit button were no within the form tags and so....

IMN logo majestic logo threadwatch logo seochat tools logo