[Javascript] Re: Javascript digest, Vol 1 #794 - 4 msgs

Lewis Shadoff lshadoff at brazosport.cc.tx.us
Wed Oct 30 12:13:11 CST 2002


Sebastian,

You can declare global variables in JavaScript.  Just put a declaration 
statement at the root level (outside all functions) like this, for example:

win1 = "";

When win1 is then modified in a function it is available globally.

At 12:01 PM 10/30/2002, Sebastian wrote:

>I tried to use win1.close() on onUnload ewent but because the two statements
>are not in the same function en error occur ( win1 is not an object...)

Lew


Lewis A. Shadoff, Ph.D.
Brazosport College
Lake Jackson, TX





More information about the Javascript mailing list