Document.expando (Property)

A means of locking objects to prevent new properties being added.


JScript - 3.0
Internet Explorer - 4.0
Property/method value type:Boolean primitive
JavaScript syntax:IEmyDocument.expando
IEmyDocument.expando = aSwitch
Argument list:aSwitchA boolean value to turn this feature on or off

When the document.expando property is set to false, it inhibits the creation of new properties if they do not already exist. This can sometimes help find bugs in your scripts. Imagine that you may have misspelled a property name. Setting this property so that it generates a runtime error when a new property is created may help you to isolate the fault.

See also:Document object