IHTMLElement::className Property
Sets or retrieves the class of the object.
Syntax
HRESULT IHTMLElement::get_className(BSTR *p); HRESULT IHTMLElement::put_className(BSTR v);
Parameters
- p
Pointer to a variable of type BSTR that receives the class or style rule.- v
BSTR that specifies the class or style rule.
Return Value
Returns S_OK if successful, or an error value otherwise.
Remarks
The class is typically used to associate a particular style rule in a style sheet with the element .
By default, the property is equal to the string assigned to the IHTMLElement::className property of the given object, or NULL if the attribute is not explicitly assigned.
In Windows Internet Explorer 8, class names, such as
hslice
andentry-title
, are used to identify portions of a webpage that can be monitored for updates ( Web Slices). For more information, see Subscribing to Content with Web Slices.