OnDocumentComplete
Description
An event handler that fires when a frame or window completes loading of the HTML document.
Once the event fires, the handler is released and cleared.
This event is useful to ensure that a frame has loaded fully before attempting to print its content.
Example
If there is a frame with an id of "report":
function printReport(url)
{
report.src = url;
factory.OnDocumentComplete(report,frameLoaded);
}
function frameLoaded()
{
factory.printing.print(false,report);
}
Syntax
v = factory.OnDocumentComplete(frameOrWindow,callback)
Parameter |
Description |
frameOrWindow |
(object) frame or window loading the content. |
callback |
(object) reference to the JScript function to call when the document is complete. |
Applies To
factory