Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Get object keys in IE?

Status
Not open for further replies.

thenewa2x

Programmer
Dec 10, 2002
349
US
In Firefox, this works:

Code:
for ( var key in obj )
    alert( key );

It would alert you of all the keys in the object. It fails in IE though and Google results only return object oriented stuff.

Any ideas as to IE equivalent of this type of loop? If not, is there a built-in method in the Object class that will tell you the keys at a particular index?

---------------------------------------
TINSTAAFL, which is why I contribute.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top