|
May 13, 2000 The window.closed Property Tips: May 2000
Yehuda Shiran, Ph.D.
|
|
The window object's methods are not consistent in that some of them can be executed even if the window has been closed, while others can't. A typical example for the first type is the close() method. The moveTo() method, on the other hand, cannot be executed if the window has been closed. The surest way to check for an open window is to test the window.closed property. The window.closed property is a Boolean value that specifies whether a window has been closed. When a window closes, the window object that represents it continues to exist, and its closed property is set to true.
Use
Internet Explorer 3 and Navigator 2 don't support the Learn more about windows in Tutorial 1.
People who read this tip also read these tips: Look for similar tips by subject: |