IconSet Class
Defines the IconSet Class.This class is only available in Office2010.When the object is serialized out as xml, its qualified name is x14:iconSet.
Inheritance Hierarchy
System.Object
DocumentFormat.OpenXml.OpenXmlElement
DocumentFormat.OpenXml.OpenXmlCompositeElement
DocumentFormat.OpenXml.Office2010.Excel.IconSet
Namespace: DocumentFormat.OpenXml.Office2010.Excel
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
Syntax
'Declaration
<ChildElementInfoAttribute(GetType(ConditionalFormattingValueObject), FileFormatVersions.Office2010)> _
<ChildElementInfoAttribute(GetType(ConditionalFormattingIcon), FileFormatVersions.Office2010)> _
<OfficeAvailabilityAttribute(FileFormatVersions.Office2010)> _
Public Class IconSet _
Inherits OpenXmlCompositeElement
'Usage
Dim instance As IconSet
[ChildElementInfoAttribute(typeof(ConditionalFormattingValueObject), FileFormatVersions.Office2010)]
[ChildElementInfoAttribute(typeof(ConditionalFormattingIcon), FileFormatVersions.Office2010)]
[OfficeAvailabilityAttribute(FileFormatVersions.Office2010)]
public class IconSet : OpenXmlCompositeElement
Remarks
The following table lists the possible child types:
ConditionalFormattingValueObject <x14:cfvo>
ConditionalFormattingIcon <x14:cfIcon>
2.6.28 CT_IconSet
Target namespace: https://schemas.microsoft.com/office/spreadsheetml/2010/main
Referenced by: CT_CfRule
A complex type that specifies properties of a conditional formatting rule that uses an icon set. The first cfvo element following this element MUST be ignored. There MUST be greater than or equal to three cfvo elements and MUST be less than or equal to five cfvo elements following this complex type.
Child Elements:
cfvo : A CT_Cfvo element that specifies a threshold value between each icon in the icon set.
cfIcon : A CT_CfIcon element that specifies a particular icon to use within an icon set. This element MUST be present if and only if custom equals “TRUE”.
Attributes:
iconSet : An ST_IconSetType attribute that specifies the icon set used.
showValue : A boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the cells in the applied range display the icon and cell value, or the icon only.
Value |
Meaning |
TRUE |
The icon and cell value are shown in the cell. |
FALSE |
Only the icon is shown in the cell. |
percent : Undefined and MUST be ignored.
reverse : A boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the icons in the icon set specified in iconSet are shown in reverse order. If custom equals “TRUE” this value MUST be ignored.
Value |
Meaning |
TRUE |
The icons specified in iconSet are shown in reverse order. |
FALSE |
The icons specified in iconSet are shown in the order defined by the icon set. |
custom : A boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether a custom set of icons is used. If this value is “TRUE” then there must be the same number of cfIcon elements as cfvo elements and the icons specified by the cfIcon elements are used rather than those specified by iconSet. If this value is “FALSE”, then there MUST be 0 cfIcon elements.
Value |
Meaning |
FALSE |
No custom set of icons is used. |
TRUE |
A custom set of icons is used. |
The following W3C XML Schema ([XMLSCHEMA1] section 2.1) fragment specifies the contents of this complex type.
<xsd:complexType name="CT_IconSet">
<xsd:sequence>
<xsd:element name="cfvo" type="CT_Cfvo" minOccurs="2" maxOccurs="unbounded"/>
<xsd:element name="cfIcon" type="CT_CfIcon" minOccurs="0" maxOccurs="5"/>
</xsd:sequence>
<xsd:attribute name="iconSet" type="ST_IconSetType" use="optional" default="3TrafficLights1"/>
<xsd:attribute name="showValue" type="xsd:boolean" use="optional" default="true"/>
<xsd:attribute name="percent" type="xsd:boolean" use="optional" default="true"/>
<xsd:attribute name="reverse" type="xsd:boolean" use="optional" default="false"/>
<xsd:attribute name="custom" type="xsd:boolean" use="optional" default="false"/>
</xsd:complexType>
See section 5.3 for the full W3C XML Schema ([XMLSCHEMA1] section 2.1).
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.