Represents the current cascaded format and style as specified by global style sheets, inline styles, and HTML attributes.
Syntax
HRESULT currentStyle( IHTMLCurrentStyle **ppCurrentStyle );
Parameters
- ppCurrentStyle
- Address of a pointer to the address of a currentStyle object.
Return Value
Returns S_OK if the function was bound successfully, or an error code otherwise.
Remarks
Through the currentStyle object returned by this method, cascaded style values of an object can be retrieved. Reading the currentStyle object differs from reading the style object, where style is not set inline on an object. For example, if the color property is set on a paragraph only through a linked or embedded style sheet, and not inline, then object.currentStyle.color will return the color, whereas object.style.color will not return a value. If, however, the author specifies <P STYLE="color:'red'">, both the currentStyle and style objects will return the value red.
See Also