Click to return to the Reusing Browser Technology home page    
IHTMLElement::toString Me...     IHTMLElement2::addBehavio...     Interfaces and Scripting ...    
Web Workshop  |  Reusing Browser Technology

IHTMLElement2 Interface


This interface provides the ability to programmatically access the properties and methods that are common to all element objects.

IHTMLElement2 Methods

addBehavior Adds the specified behavior to the list of behaviors influencing this element.
addFilter Adds the specified filter to the list of filters influencing this element.
applyElement Applies the given element at the given location.
attachEvent Binds the specified function to an event, so that the function gets called whenever the event fires on the object.
blur Causes the element to lose focus, and fires the onblur event.
clearAttributes Clears the attributes of the element.
componentFromPoint Returns the component located at the specified coordinates.
createControlRange Creates a selection range object for control-based selection rather than text-based selection.
currentStyle Represents the current cascaded format and style as specified by global style sheets, inline styles, and HTML attributes.
detachEvent Unbinds the specified object from the event so that the object stops being called whenever the event fires.
doScroll Simulates a scroll click on a component.
focus Causes a control to receive the focus, and executes the code specified by the onfocus event.
get_accessKey Retrieves the accessKey property of the element.
get_canHaveChildren Retrieves the value that indicates whether the element can have children.
get_clientHeight Retrieves the height of the element's client area, in pixels.
get_clientLeft Retrieves the distance, in pixels, between the offsetLeft and the true left side of the client area.
get_clientTop Retrieves the distance, in pixels, between the offsetTop and the true top of the client area.
get_clientWidth Retrieves the element's client area width, in pixels.
get_dir Retrieves the reading order of the element.
get_onbeforecopy Retrieves a pointer to the event handler function associated with the onbeforecopy event of the element.
get_onbeforecut Retrieves a pointer to the event handler function associated with the onbeforecut event of the element.
get_onbeforeeditfocus Retrieves a pointer to the event handler function associated with the onbeforeeditfocus event of the element.
get_onbeforepaste Retrieves a pointer to the event handler function associated with the onbeforepaste event of the element.
get_onblur Retrieves a pointer to the event handler function associated with the onblur event on the element.
get_oncellchange Retrieves a pointer to the event handler function associated with the element's oncellchange event.
get_oncontextmenu Retrieves a pointer to the event handler function associated with the element's oncontextmenu event.
get_oncopy Retrieves a pointer to the event handler function associated with the oncopy event of the element.
get_oncut Retrieves a pointer to the event handler function associated with the oncut event of the element.
get_ondrag Retrieves a pointer to the event handler function associated with the ondrag event of the element.
get_ondragend Retrieves a pointer to the event handler function associated with the ondragend event of the element.
get_ondragenter Retrieves a pointer to the event handler function associated with the ondragenter event of the element.
get_ondragleave Retrieves a pointer to the event handler function associated with the ondragleave event of the element.
get_ondragover Retrieves a pointer to the event handler function associated with the ondragover event of the element.
get_ondrop Retrieves a pointer to the event handler function associated with the ondrop event of the element.
get_onfocus Retrieves a pointer to the event handler function associated with the onfocus event on the element.
get_onlosecapture Retrieves a pointer to the event handler function associated with the onlosecapture event of the element.
get_onpaste Retrieves a pointer to the event handler function associated with the onpaste event of the element.
get_onpropertychange Retrieves a pointer to the event handler function associated with the onpropertychange event of the element.
get_onreadystatechange Retrieves a pointer to the event handler function associated with the onreadystatechange event of the element.
get_onresize Retrieves a pointer to the event handler function associated with the onresize event of the element.
get_onrowsdelete Retrieves a pointer to the event handler function associated with the onrowsdelete event of the element.
get_onrowsinserted Retrieves a pointer to the event handler function associated with the element's onrowsinserted event of the element.
get_onscroll Retrieves a pointer to the event handler function associated with the onscroll event of the element. The default action of this event is to scroll.
get_runTimeStyle Retrieves the element's runtimeStyle object.
get_scopeName Retrieves the element's scopeName property.
get_scrollHeight Retrieves the element's scrolling height, in pixels.
get_scrollLeft Retrieves the distance, in pixels, between the left edge of the element and the leftmost portion of the content currently visible in the window.
get_scrollTop Retrieves the distance, in pixels, between the top of the object and the topmost portion of the content currently visible in the window.
get_scrollWidth Retrieves the element's scrolling width, in pixels.
get_tabIndex Retrieves the tabIndex property of the element.
get_tagUrn Retrieves the universal resource name (URN) of the element.
getAdjacentText Returns the adjacent text character.
getBoundingClientRect Retrieves a reference to a rectangle object that bounds a collection of TextRectangle objects.
getClientRects Retrieves a collection of rectangles that describe the layout of the contents of an object or range. Each rectangle describes a single line.
getElementsByTagName Retrieves a collection of all elements with a specific tagName property existing in the document.
getExpression Retrieves the expression for the given property.
insertAdjacentElement Inserts the given element at the given location.
mergeAttributes Merges the attributes of two elements.
put_accessKey Sets the accessKey property of the element.
put_dir Sets the reading order of the element.
put_onbeforecopy Sets a pointer to the event handler function associated with the onbeforecopy event of the element.
put_onbeforecut Sets a pointer to the event handler function associated with the onbeforecut event of the element.
put_onbeforeeditfocus Sets a pointer to the event handler function associated with the onbeforeeditfocus event of the element.
put_onbeforepaste Sets a pointer to the event handler function associated with the onbeforepaste event of the element.
put_onblur Sets a pointer to the event handler function associated with the onblur event on the element.
put_oncellchange Sets a pointer to the event handler function associated with the element's oncellchange event.
put_oncontextmenu Sets a pointer to the event handler function associated with the element's oncontextmenu event.
put_oncopy Sets a pointer to the event handler function associated with the oncopy event of the element.
put_oncut Sets a pointer to the event handler function associated with the oncut event of the element.
put_ondrag Sets a pointer to the event handler function associated with the ondrag event of the element.
put_ondragend Sets a pointer to the event handler function associated with the ondragend event of the element.
put_ondragenter Sets a pointer to the event handler function associated with the ondragenter event of the element.
put_ondragleave Sets a pointer to the event handler function associated with the ondragleave event of the element.
put_ondragover Sets a pointer to the event handler function associated with the ondragover event of the element.
put_ondrop Sets a pointer to the event handler function associated with the ondrop event of the element.
put_onfocus Sets a pointer to the event handler function associated with the onfocus event on the A element.
put_onlosecapture Sets a pointer to the event handler function associated with the onlosecapture event of the element.
put_onpaste Sets a pointer to the event handler function associated with the onpaste event of the element.
put_onpropertychange Sets a pointer to the event handler function associated with the onpropertychange event of the element.
put_onreadystatechange Sets a pointer to the event handler function associated with the onreadystatechange event of the element.
put_onresize Sets a pointer to the event handler function associated with the onresize event of the element.
put_onrowsdelete Sets a pointer to the event handler function associated with the onrowsdelete event of the element.
put_onrowsinserted Sets a pointer to the event handler function associated with the element's onrowsinserted event of the element.
put_onscroll Sets a pointer to the event handler function associated with the onscroll event of the element. The default action of this event is to scroll.
put_scrollLeft Sets the distance, in pixels, between the left edge of the element and the leftmost portion of the content currently visible in the window.
put_scrollTop Sets the distance, in pixels, between the top of the object and the topmost portion of the content currently visible in the window.
put_tabIndex Sets the tabIndex property of the element.
put_tagUrn Sets the universal resource name (URN) of the element.
releaseCapture Releases mouse capture from an object belonging to the current document.
removeBehavior Removes the specified behavior from the list of behaviors influencing this element.
removeExpression Removes the expression for the given property.
removeFilter Removes the specified filter from the list of filters influencing this element.
replaceAdjacentText Replaces the adjacent text character.
setCapture Sets the mouse capture to the object belonging to the current document.
setExpression Sets an expression for an element object.

Interface Information

Implementation System (Mshtml.dll)
Inherits from IDispatch
Header and IDL files Mshtml.h, Mshtml.idl
Minimum availability Internet Explorer 5
Minimum operating systems Windows 95, Windows NT 4.0


Back to topBack to top

Did you find this topic useful? Suggestions for other topics? Write us!

© 1999 Microsoft Corporation. All rights reserved. Terms of use.