DivId Class
Defines the DivId Class.When the object is serialized out as xml, its qualified name is w:divId.
Inheritance Hierarchy
System.Object
DocumentFormat.OpenXml.OpenXmlElement
DocumentFormat.OpenXml.OpenXmlLeafElement
DocumentFormat.OpenXml.Wordprocessing.DivId
Namespace: DocumentFormat.OpenXml.Wordprocessing
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
Syntax
'Declaration
Public Class DivId _
Inherits OpenXmlLeafElement
'Usage
Dim instance As DivId
public class DivId : OpenXmlLeafElement
Remarks
[ISO/IEC 29500-1 1st Edition]
17.3.1.10 divId (Associated HTML div ID)
This element specifies that this paragraph should be located within the specified HTML div tag when this document is saved in HTML format. This ID is then used to look up the associated div stored in the divs (§17.15.2.8) element. [Note: This element is used to preserve the fidelity of existing HTML documents when saved in the WordprocessingML format. end note].
If the paragraph does not specify this element, then any div referenced by the previous paragraph is closed, and this paragraph shall not belong to any div when saved as HTML. If this specified id does not exist in the collection of divs the current document, then any div referenced by the previous paragraph is closed, and this paragraph shall not belong to any div when saved as HTML.
[Example: Consider the following WordprocessingML paragraph fragment:
<w:p> <w:pPr> <w:divId w:val="1512645511" /> </w:pPr> </w:p>
This paragraph specifies that it belongs to the HTML div with id 1512645511, stored in the divs element. end example]
Parent Elements |
---|
pPr (§17.3.1.26); pPr (§17.3.1.25); pPr (§17.7.5.2); pPr (§17.7.6.1); pPr (§17.9.23); pPr (§17.7.8.2) |
Attributes |
Description |
---|---|
val (Decimal Number Value) |
Specifies that the contents of this attribute contains a decimal number. The contents of this decimal number are interpreted based on the context of the parent XML element. [Example: Consider the following numeric WordprocessingML property of simple type ST_DecimalNumber: <… w:val="1512645511" /> The value of the val attribute is a decimal number whose value must be interpreted in the context of the parent element. end example] The possible values for this attribute are defined by the ST_DecimalNumber simple type (§17.18.10). |
[Note: The W3C XML Schema definition of this element’s content model (CT_DecimalNumber) is located in §A.1. end note]
[ISO/IEC 29500-1 1st Edition]
17.4.9 divId (Associated HTML div ID)
This element specifies the HTML div information which is associated with the current table row. This information, stored in the Web Settings part, is used to associate one or more table rows with a particular HTML div element. [Note: This property is used when saving an HTML document into the WordprocessingML format in order to prevent a loss of all HTML div information, so that the document can later be saved back into HTML format and have the stored information replaced, since the HTML div can store formatting properties on arbitrary regions. end note]
In order to determine the associated HTML div properties, the value of the val attribute on this element is used to look up an associated div element (§17.15.2.8) whose id attribute matches this value.
If this table row does not have a divId element present, then this table row shall not have any associated HTML div information. If this element is present, but the val attribute specifies an id value which does not have an associated div element, then this element is ignored.
[Example: Consider an HTML document defined as follows:
<html> <body> <div style="…"> <table> <tr> <td>R1C1</td> … </tr> </table> <p> … </p> </div> … </body> </html>
This HTML document specifies a div spanning the table and the first paragraph. If this document is saved into WordprocessingML, then both the rows of the table and the paragraph must have a divId which points at the same div information in the web settings part:
<w:trPr> … <w:divId w:val="1102603671"/> </w:trPr>
The val attribute then points at a div element which stores the associated div properties:
<w:divs> <w:div w:id="1102603671"> … </w:div> </w:divs>
This specifies that this table's rows are part of a single HTML div. end example]
Parent Elements |
---|
trPr (§17.4.82); trPr (§17.7.6.10); trPr (§17.7.6.11); trPr (§17.4.83) |
Attributes |
Description |
---|---|
val (Decimal Number Value) |
Specifies that the contents of this attribute contains a decimal number. The contents of this decimal number are interpreted based on the context of the parent XML element. [Example: Consider the following numeric WordprocessingML property of simple type ST_DecimalNumber: <… w:val="1512645511" /> The value of the val attribute is a decimal number whose value must be interpreted in the context of the parent element. end example] The possible values for this attribute are defined by the ST_DecimalNumber simple type (§17.18.10). |
[Note: The W3C XML Schema definition of this element’s content model (CT_DecimalNumber) is located in §A.1. end note]
© ISO/IEC29500: 2008.
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.