次の方法で共有


ConditionalFormat Class

Defines the ConditionalFormat Class.This class is only available in Office2010.When the object is serialized out as xml, its qualified name is x14:conditionalFormat.

Inheritance Hierarchy

System.Object
DocumentFormat.OpenXml.OpenXmlElement
DocumentFormat.OpenXml.OpenXmlCompositeElement
DocumentFormat.OpenXml.Office2010.Excel.ConditionalFormat

Namespace: DocumentFormat.OpenXml.Office2010.Excel
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)

Syntax

'宣言
<ChildElementInfoAttribute(GetType(ExtensionList), FileFormatVersions.Office2010)> _
<ChildElementInfoAttribute(GetType(PivotAreas), FileFormatVersions.Office2010)> _
<OfficeAvailabilityAttribute(FileFormatVersions.Office2010)> _
Public Class ConditionalFormat _
    Inherits OpenXmlCompositeElement
'使用
Dim instance As ConditionalFormat
[ChildElementInfoAttribute(typeof(ExtensionList), FileFormatVersions.Office2010)]
[ChildElementInfoAttribute(typeof(PivotAreas), FileFormatVersions.Office2010)]
[OfficeAvailabilityAttribute(FileFormatVersions.Office2010)]
public class ConditionalFormat : OpenXmlCompositeElement

Remarks

The following table lists the possible child types:

  • PivotAreas <x14:pivotAreas>

  • ExtensionList <x14:extLst>

2.6.50 CT_ConditionalFormat

Target namespace: https://schemas.microsoft.com/office/spreadsheetml/2010/main

Referenced by: CT_ConditionalFormats

This complex type specifies the scope, type and priority of conditional formatting applied to this PivotTable ([ISO/IEC-29500-1] section 18.10) view.

Child Elements:

pivotAreas : A CT_PivotAreas ([ISO/IEC-29500-4] section A.2) element that specifies a set of PivotTable areas this conditional formatting applies to.

extLst : A CT_ExtensionList ([ISO/IEC-29500-4] section A.2) element that specifies future extensibility for this element.

Attributes:

scope : An ST_Scope ([ISO/IEC-29500-1] section 18.18.67) attribute that specifies the scope of this conditional formatting.

type : An ST_Type ([ISO/IEC-29500-1] section 18.18.84) attribute that MUST NOT be present or MUST be equal to "none".

priority : An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the priority of the PivotTable conditional formatting. This value MUST be greater than or equal to 1. If this attribute is present, there MUST exist a CT_CfRule with a priority attribute equal to the value of this field and it MUST be the same CT_CfRule element that is specified by id. The CT_CfRule specified by this value MUST have an ancestor CT_ConditionalFormatting element with a pivot attribute equal to "TRUE".

id : An ST_Guid ([ISO/IEC-29500-1] section 22.9.2.4) attribute that specifies a particular CT_CfRule. There MUST exist a CT_CfRule with an id attribute equal to this value and it MUST be the same CT_CfRule element that is specified by priority.<40>

The following W3C XML Schema ([XMLSCHEMA1] section 2.1) fragment specifies the contents of this complex type.

<xsd:complexType name="CT_ConditionalFormat">

<xsd:sequence>

<xsd:element name="pivotAreas" type="x:CT_PivotAreas" minOccurs="0" maxOccurs="1"/>

<xsd:element name="extLst" minOccurs="0" maxOccurs="1" type="x:CT_ExtensionList"/>

</xsd:sequence>

<xsd:attribute name="scope" type="x:ST_Scope" default="selection" use="optional"/>

<xsd:attribute name="type" type="x:ST_Type" default="none" use="optional"/>

<xsd:attribute name="priority" use="optional" type="xsd:unsignedInt"/>

<xsd:attribute name="id" type="x:ST_Guid" use="required"/>

</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.

See Also

Reference

ConditionalFormat Members

DocumentFormat.OpenXml.Office2010.Excel Namespace