Control Class
Defines the Control Class.When the object is serialized out as xml, its qualified name is w:control.
Inheritance Hierarchy
System.Object
DocumentFormat.OpenXml.OpenXmlElement
DocumentFormat.OpenXml.OpenXmlLeafElement
DocumentFormat.OpenXml.Wordprocessing.Control
Namespace: DocumentFormat.OpenXml.Wordprocessing
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
Syntax
'Declaración
Public Class Control _
Inherits OpenXmlLeafElement
'Uso
Dim instance As Control
public class Control : OpenXmlLeafElement
Remarks
[ISO/IEC 29500-1 1ª edición]
17.3.3.3 control (Embedded Control)
This element specifies that the parent embedded object is a representation of an embedded control. This element shall be used to associate the appropriate embedded control settings and properties when the document is displayed.
If the embedded control is not present, cannot be loaded due to application settings, or is not supported, then a suitable placeholder image shall be used to provide a representation of the presence of an embedded control at the appropriate location in the document.
[Example: Consider a run which consists of an embedded control. That run would be specified using the following WordprocessingML:
<w:r>
<w:object>
…
<w:control r:id="rId99" w:shapeid="10" … />
</w:object>
</w:r>
The control element indicates that the parent embedded object is an embedded control, whose settings and properties are stored on this element and the (optional) target of the relationship specified using the id attribute. end example]
Parent Elements |
---|
object (§17.3.3.19) |
Attributes |
Description |
---|---|
id (Embedded Control Properties Relationship Reference) Namespace: .../officeDocument/2006/relationships |
Specifies the relationship ID for the relationship which contains the properties for this embedded control. This property bag is contained in a separate part within the Office Open XML package. The relationship explicitly targeted by this attribute shall be of type https://schemas.openxmlformats.org/officeDocument/2006/relationships/control or the document shall be conisdered non-conformant. If this attribute is omitted, then the embedded control shall be given no property bag when instantiated. [Example: Consider the following WordprocessingML markup for an embedded control in a document:
The id attribute in the relationship reference namespace specifies that the relationship with relationship ID rId5 must contain the property data for this embedded control. end example] The possible values for this attribute are defined by the ST_RelationshipId simple type (§22.8.2.1). |
name (Unique Name for Embedded Control) |
Specifies a unique name for this embedded control. This name shall be unique across all controls in this document. [Example: Consider the following WordprocessingML markup for an embedded control in a document:
The name attribute specifies that the unique name for this control must be CheckBox1. end example] The possible values for this attribute are defined by the ST_String simple type (§22.9.2.13). |
shapeid (Shape Reference) |
Specifies the shape ID for a shape which shall be used to define the presentation and location of this embedded control within the document if the control is floating using the DrawingML syntax. [Note: This positioning data is sufficient to display the control in any case where:
end note] This shape ID reference is resolved by looking for a DrawingML object whose id attribute matches the value specified within this attribute. If no such shape exists, then the control shall be rendered inline in the document content at the current run content location. If this attribute is omitted, then this embedded control shall be displayed inline in the current location in the parent run. [Example: Consider the following WordprocessingML markup for an embedded control in a document:
The shapeid attribute specifies that the DrawingML object with an id attribute value of 10 must contain the positioning data for this embedded control. end example] The possible values for this attribute are defined by the ST_String simple type (§22.9.2.13). |
[Note: The W3C XML Schema definition of this element's content model (CT_Control) is located in §A.1. end note]
[ISO/IEC 29500-1 1ª edición]
9.2.2.1 control (Floating Embedded Control)
This element specifies that the parent VML object is a representation of an embedded control at the current location in the document. This element shall be used to associate the VML data with the appropriate embedded control settings and properties when the document is displayed.
If the embedded control is not present, cannot be loaded due to application settings, or is not supported, then the VML data shall be used to provide an image representation of the control at the appropriate location in the document.
[Example: Consider a run which consists of an embedded control. That run would be specified using the following WordprocessingML:
<w:r>
<w:pict>
…
<w:control r:id="rId99" w:shapeid="shape01" … />
</w:pict>
</w:r>
The control element indicates that the parent VML object contains the positioning and last known image representation of an embedded control, whose settings and properties are stored on this element. end example]
Parent Elements |
---|
pict (§9.2.2.2); pict (§9.5.1) |
Attributes |
Description |
---|---|
id (Embedded Control Properties Relationship Reference) Namespace: .../officeDocument/2006/relationships |
Specifies the relationship ID for the relationship which contains the properties for this embedded control. This property bag is contained in a separate part within the Office Open XML package. The relationship explicitly targeted by this attribute shall be of type https://schemas.openxmlformats.org/officeDocument/2006/relationships/control or the document shall be conisdered non-conformant. If this attribute is omitted, then the embedded control shall be given no property bag when instantiated. [Example: Consider the following WordprocessingML markup for an embedded control in a document:
The id attribute in the relationship reference namespace specifies that the relationship with relationship ID rId5 must contain the property data for this embedded control. end example] The possible values for this attribute are defined by the ST_RelationshipId simple type (Part 1, §22.8.2.1). |
name (Unique Name for Embedded Control) |
Specifies a unique name for this embedded control. This name shall be unique across all controls in this document. [Example: Consider the following WordprocessingML markup for an embedded control in a document:
The name attribute specifies that the unique name for this control must be CheckBox1. end example] The possible values for this attribute are defined by the ST_String simple type (Part 1, §22.9.2.13). |
shapeid (Shape Reference) |
Specifies the shape ID for a shape which shall be used to define the presentation and location of this embedded control within the document if the control is floating using the DrawingML syntax. [Note: This positioning data is sufficient to display the control in any case where:
end note] This shape ID reference is resolved by looking for a DrawingML object whose id attribute matches the value specified within this attribute. If no such shape exists, then the control shall be rendered inline in the document content at the current run content location. If this attribute is omitted, then this embedded control shall be displayed inline in the current location in the parent run. [Example: Consider the following WordprocessingML markup for an embedded control in a document:
The shapeid attribute specifies that the DrawingML object with an id attribute value of 10 must contain the positioning data for this embedded control. end example] The possible values for this attribute are defined by the ST_String simple type (Part 1, §22.9.2.13). |
[Note: The W3C XML Schema definition of this element's content model (CT_Control) is located in §A.1. end note]
© ISO/IEC29500: 2008. Los extractos anteriores han sido traducidos del inglés al español por Microsoft (o algunos de sus agentes) e ISO no asume ningún tipo de responsabilidad por dichas traducciones.
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.