ondocumentready Event

MS Office DHTML, HTML & CSS

 
Click to return to the Component Development home page    
ondetach Event     HTC Reference    

ondocumentready Event


Fires when the behavior's containing document has been completely parsed.

Syntax

<PUBLIC:ATTACH
    EVENT = ondocumentready
    ONEVENT = sEventHandler
    FOR = element
    ID = sID
/>

Attributes

EVENT
Required. String that specifies the name of a Dynamic HTML (DHTML) event, or any of the events specific to the HTML Component (HTC) that are listed in the HTC Reference.
FOR
Optional. String that specifies one of the following values to identify the source of the event.
document Refers to the document object.
element Default. Refers to the element to which the behavior is attached.
window Refers to the window object.
ONEVENT
Required. String that specifies an inline script or a direct invocation of the event handler function.
ID
Optional. String that uniquely identifies the ATTACH element within the component. This attribute is analogous to the ID attribute in DHTML.

Remarks

The ondocumentready event fires after all scripts, images, Microsoft® ActiveX® controls, and all other elements on the page are completely downloaded.

A behavior attached to an element receives both the ondocumentready and oncontentready notifications, but only after the window.onload event fires.

See Also

dhtml behaviorsInternet Link, implementing dhtml behaviors in scriptInternet Link


Back to topBack to top

Did you find this topic useful? Suggestions for other topics? write us!Internet Link

© 1999 microsoft corporation. all rights reserved. terms of useInternet Link.