Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] RE: Undefined is Undefined in IE 5


  • From: costea.dan at ssi-schaefer.ro (Dan Costea)
  • Subject: [Javascript] RE: Undefined is Undefined in IE 5
  • Date: Wed Dec 10 00:54:36 2003

undefined - is a reserved key word, so you should use it without ". If you say: "undefined" - this is just a string. I used undefined in IE5 and IE6 and it worked fine... But in your case, I think is better to use:

var AverageStudentsObj = document.getElementById("AverageStudents"); 
  if (AverageStudentsObj)
    alert (AverageStudentsObj);
  else
    alert ('object not found');

Dan.
  ----- Original Message ----- 
  From: bill.marriott@xxxxxxxxxxxxxxxx 
  To: [JavaScript List] 
  Sent: Wednesday, December 10, 2003 2:17 AM
  Subject: [Javascript] RE: Undefined is Undefined in IE 5



  HI Everyone, 

  The following code works in IE 6 but falls over with the error "Undefined is Undefined" 
  in IE 5.  Does anyone know what the actual problem is and is there  a workaround? 

  var AverageStudentsObj = document.getElementById("AverageStudents"); 
    if ( AverageStudentsObj != undefined ) 

  thanks 

  Bill Marriott
  Analyst/Programmer
  Information Technology
  NSW Agriculture
  Orange

  Ph.  02 6391 3657
  Fax. 02 6391 3290


  This message is intended for the addressee named and may contain confidential information. If you are not the intended recipient or received it in error, please delete the message and notify sender. Views expressed are those of the individual sender and are not necessarily the views of their organisation.


------------------------------------------------------------------------------


  _______________________________________________
  Javascript mailing list
  Javascript@xxxxxxxxxx
  https://lists.LaTech.edu/mailman/listinfo/javascript
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.LaTech.edu/pipermail/javascript/attachments/20031210/b0cf0718/attachment.html