Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

counterReset property

Sets or retrieves a list of counters to create or reset to zero.

CSS 2.1, Section 12.4Internet Explorer 8


HRESULT value = object.put_counterReset( v);HRESULT value = object.get_counterReset(* p);

Property values

Type: BSTR

a space-delimited list of counters, including one or both of the value in Possible Values.

identifier (identifier)

The name of the counter, optionally followed by an integer.

integer (integer)

The initial value of the counter. The default value is 0.

String format

[ <identifier> <integer> ]+

CSS information

Applies ToAll elements
Initial Value

Standards information


The IHTMLCurrentStyle5::counterReset attribute can contain a list of one or more counters, each one optionally followed by an integer. The integer represents the value that the counter is set to after each occurrence of the element.

If an element both resets and increments a counter, the counter is reset first and then incremented. If the same counter is specified more than once, each reset or increment of the counter is processed in the order specified.

The IHTMLCurrentStyle5::counterIncrement and IHTMLCurrentStyle5::counterReset attributes follow the rules of the CSS cascade. Given two style declarations with the same specificity, only the last one encountered will be processed. For more information about cascade and specificity, see Understanding CSS Selectors.

An element that is not displayed (IHTMLRuleStyle::display attribute set to 'none') and pseudo-elements that do not generate content (IHTMLCurrentStyle5::content attribute set to 'normal') cannot increment or reset a counter.

This property requires Windows Internet Explorer to be in IE8 Standards mode rendering.


Minimum supported client

Windows XP with SP2 [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]







See also




Community Additions

© 2014 Microsoft. All rights reserved.