Anyone know how to determine if an object variable is set/exists?
I'm using an object variable that contains another open explorer window, but I need to know if the user has closed that window
Win2=window.open("Sample.htm","","height=100,width=100,top=100,left=100"
Win2.creator = self
Then, later in the program, if the user clicks a button I show the object win2 using...
win2.focus()[
But, if the user has accidentally closed this window I get an object not set error, how can I check to see if the object is initialised before I reference it. If it's been accidentally closed, I could then reopen it before setting it as the focus.
Thanks in advance,
Peter
I'm using an object variable that contains another open explorer window, but I need to know if the user has closed that window
Win2=window.open("Sample.htm","","height=100,width=100,top=100,left=100"

Win2.creator = self
Then, later in the program, if the user clicks a button I show the object win2 using...
win2.focus()[
But, if the user has accidentally closed this window I get an object not set error, how can I check to see if the object is initialised before I reference it. If it's been accidentally closed, I could then reopen it before setting it as the focus.
Thanks in advance,
Peter