removeRule Method
Removes the cascading style sheet rule at the specified position.
expression.removeRule(lIndex)
*expression * Required. An expression that returns one of the objects in the Applies To list.
lIndex Required Long. Specifies a zero-based number that indicates the ordinal position of the selector.
Remarks
The removeRule method removes all cascading style sheet rules for a selector. For example, if there are multiple style sheet attributes that affect the BODY element, all style attributes are removed.
The removeRule method only removes cascading style sheet rules from STYLE elements in a page and does not modify external style sheets referenced.
Example
The following example removes the first cascading style sheet rule in the first cascading style sheet in the active document.
Dim objCSS As FPHTMLStyleSheet
Set objCSS = ActiveDocument.styleSheets(0)
objCSS.removeRule 0
Applies to | FPHTMLStyleSheet Object | IHTMLStyleSheet Object