Solved

ASP.NET 'contentWindow.document is null' error

Posted on 2004-03-30
5
295 Views
Last Modified: 2008-03-17
Does anyone know more about this error and maybe how to fix it? It happens when I call button click from javascript: Form1.button1.click();

Thanks
0
Comment
Question by:gromul
  • 3
  • 2
5 Comments
 
LVL 12

Expert Comment

by:venkateshwarr
ID: 10720526
Is the current window open?

do the check
if (contentWindow.document)
{

}
0
 

Author Comment

by:gromul
ID: 10720570
I tried that but get an error message that the contentWindow is undefined. How do I define it?
0
 
LVL 12

Accepted Solution

by:
venkateshwarr earned 500 total points
ID: 10720727
simply go one level up and do the check

if (contentWindow)
{

}

0
 

Author Comment

by:gromul
ID: 10721964
It says that contentWindow is undefined also. What I don't understand is: what's the relationship between calling the button click and contentWindow?
0
 

Author Comment

by:gromul
ID: 10731028
Thanks venkateshwarr.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now