javascript error, is there something wrong with this ?

  • Thread starter Thread starter Ashish
  • Start date Start date
A

Ashish

hi all ,
Iam adding the following javascript by

RegisterStartScript("myscript", "<script language='JavaScript'> var
agree = confirm('are you sure you wanna do this ?'); if (agree){
document.forms[0].submit(); } </script>")

adding this , the page does executes the script and message pop ups,
but then i get the following error

Microsoft JScript runtime error: 'contentWindow.document' is null or not
an object

is there something wrong iam doing, it used to work for me ?


any help would appreciated

TIA
-ashish
 
Sounds like your page may be missing a body tag.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
 
I'm not sure, but it could also be a missing "<html>" tag.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
 
Kevin said:
I'm not sure, but it could also be a missing "<html>" tag.

the page is being created properly with all the tags, but there is
something unique i observed, if i set smartnavigation="false" in the
web.config, it works just fine ....

any reasons for this behavior ?

-ashish
 
Never used it (SmartNavigation). However, someone else will probably pick
this up!

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
 
Back
Top