FormControlProperties class

Office 2013 and later

Defines the FormControlProperties Class. The root element of ControlPropertiesPart. When the object is serialized out as xml, its qualified name is x14:formControlPr.

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

No code example is currently available or this language may not be supported.

2.4.34 formControlPr

Target namespace: http://schemas.microsoft.com/office/spreadsheetml/2009/9/main

A formControlPr element is a CT_FormControlPr type element, as specified in section 2.6.65, that specifies properties of form control objects. This element is the root element of the control properties part, as specified in section 2.1.1.

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

<xsd:element name="formControlPr" type="CT_FormControlPr"/>

See section 5.4 for the full W3C XML Schema ([XMLSCHEMA1] section 2.1).

2.6.65 CT_FormControlPr

Target namespace: http://schemas.microsoft.com/office/spreadsheetml/2009/9/main

Referenced by: formControlPr

A complex type that stores a form control’s properties.

Child Elements:

itemLst: A CT_ListItems element, as specified in section 2.6.64, that specifies a list of items to populate a list box or drop-down form control.

extLst: A CT_ExtensionList element, as specified in [ISO/IEC-29500-4] section A.2, that specifies future extensibility for this element.

Attributes:

objectType: An ST_ObjectType attribute that specifies the form control object type.

checked: An ST_Checked attribute that specifies whether a check box is selected or a radio button is selected. This attribute only applies to check box and radio button form controls.

colored: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether a drop-down object has a color applied to it. This attribute only applies to drop-down form controls.

dropLines: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the number of lines in the drop-down before scroll bars are added. This attribute only applies to drop-down form controls. This value MUST be at least 0 and at most 30000.

dropStyle: An ST_DropStyle attribute that specifies the style of the drop-down. This attribute only applies to drop-down form controls.

dx: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the width of the scroll bar in pixels. This attribute only applies to list boxes, scroll bars, spin boxes and drop-downs<55>.

firstButton: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the object is the first button in a set of radio buttons. This attribute only applies to radio button form controls.

fmlaGroup: An ST_Formula ([ISO/IEC-29500-1] section 18.18.35) attribute that specifies the cell an object in a group box is linked to. This attribute overrides the attribute fmlaLink for any radio buttons within a group box. This attribute only applies to group box form controls. The application can chose to remove and not save this element and use the attribute fmlaLink of the first radio button in the group. This attribute MUST be a cell reference (see [ISO/IEC-29500-1] section 18.17.2.3).

fmlaLink: An ST_Formula ([ISO/IEC-29500-1] section 18.18.35) attribute that specifies the cell the object is linked to. This attribute only applies to check boxes, radio buttons, scroll bars, spin boxes, drop-downs and list boxes. The value in the linked cell and the index of the selected item in the object are linked together. This link is ignored if the form control allows multiple selections. This attribute MUST be a cell reference (see [ISO/IEC-29500-1] section 18.17.2.3).

fmlaRange: An ST_Formula ([ISO/IEC-29500-1] section 18.18.35) attribute that specifies the range of source data cells. This is used to populate a list box or a drop-down form control<56>. This attribute only applies to list box and drop-down form controls. This attribute MUST be a cell reference (see [ISO/IEC-29500-1] section 18.17.2.3).

fmlaTxbx: An ST_Formula ([ISO/IEC-29500-1] section 18.18.35) attribute that specifies the source data cell that the form control object’s data is linked to. Any cell range MAY be specified but only the first cell in the range is considered. This attribute applies only to label and edit box form controls. This attribute MUST be a cell reference (see [ISO/IEC-29500-1] section 18.17.2.3).

horiz: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the scroll bar is horizontal. This attribute only applies to scroll bar form controls.

inc: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the change in the current value of a scroll bar or a spin box form control as a result of on an increment click. If present, it MUST be at least 0 and at most 30000. This attribute applies only to scroll bar or spin box form controls.

justLastX: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the last line in text is justified when in an East Asian alignment<57>.

lockText: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the object’s text is locked. This attribute applies only to button, radio button, check box and label form controls.

max: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the maximum value generated by the scroll bar (when scrolled all the way down) or by the spin box. It MUST be at least 0 and at most 30000. This attribute only applies to scroll bars and spin boxes.

min: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the minimum value generated by the scroll bar (when scrolled all the way up) or by the spin box. It MUST be at least 0 and at most 30000. This attribute only applies to scroll bars and spin box.

multiSel: A string ([XMLSCHEMA2] section 3.2.1) attribute that specifies the indices of selected items as a comma-delimited list. The list indices are one-based. This attribute is valid only if the attribute selType has the value "multi". This attribute applies only to list box form controls.

noThreeD: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether 3-D effects are disabled. This attribute only applies to check box, radio button, group box, scroll bar, drop-down, list box, and spin box form controls.

noThreeD2: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether 3-D effects are disabled. This element is used for drop-downs and list boxes<58>.

page: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the number of items to move the scroll bar or spin box on a page click. It MUST be at least 0 and at most 30000<59>.

sel: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the index of the selected item. The list indices are one-based. If set to a value of 0, no items are selected. This attribute applies only to list box and drop-down form controls.

seltype: An ST_SelType attribute that specifies the selection type for the list box. This attribute applies only to list box form controls.

textHAlign: An ST_TextHAlign attribute that specifies the horizontal text alignment for the object<60>.

textVAlign: An ST_TextVAlign attribute that specifies the vertical text alignment for the object<61>.

val: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the number of top rows (2) currently hidden in the scroll bar. If omitted, the value is assumed to be 0. Those rows (2) are hidden but still accessible by clicking the scroll bar buttons. The number of top hidden rows (2) can change as the user interacts with the scroll bar. This attribute only applies to scroll bar, spin box, list box, and drop-down form controls.

widthMin: An unsignedInt ([XMLSCHEMA2] section 3.3.22) attribute that specifies the smallest width allowed for the drop-down box window in screen pixels. This attribute only applies for drop-down form controls.

editVal: An ST_EditValidation attribute that specifies how the edit box content is validated if the application chooses to validate it. This attribute only applies to edit box form controls.

multiLine: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the form control is multiline. This attribute only applies to edit box form controls. This attribute only works when the form control is run in a dialog box.

verticalBar: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the control has a vertical scroll bar. This attribute only applies to edit box form controls. This attribute only works when the form control is run in a dialog box.

passwordEdit: A Boolean ([XMLSCHEMA2] section 3.2.2) attribute that specifies whether the edit box control stores a password. In this case the control will display * for every character on it. This attribute only applies to edit box form controls. This attribute only works when the control is run in a dialog box.

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

<xsd:complexType name="CT_FormControlPr">

<xsd:sequence>

<xsd:element name="itemLst" type="CT_ListItems" minOccurs="0" maxOccurs="1"/>

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

</xsd:sequence>

<xsd:attribute name="objectType" type="ST_ObjectType" use="optional"/>

<xsd:attribute name="checked" type="ST_Checked" use="optional"/>

<xsd:attribute name="colored" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="dropLines" type="xsd:unsignedInt" use="optional" default="8"/>

<xsd:attribute name="dropStyle" type="ST_DropStyle" use="optional"/>

<xsd:attribute name="dx" type="xsd:unsignedInt" use="optional" default="80"/>

<xsd:attribute name="firstButton" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="fmlaGroup" type="x:ST_Formula" use="optional"/>

<xsd:attribute name="fmlaLink" type="x:ST_Formula" use="optional"/>

<xsd:attribute name="fmlaRange" type="x:ST_Formula" use="optional"/>

<xsd:attribute name="fmlaTxbx" type="x:ST_Formula" use="optional"/>

<xsd:attribute name="horiz" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="inc" type="xsd:unsignedInt" use="optional" default="1"/>

<xsd:attribute name="justLastX" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="lockText" type="xsd:boolean" use="optional" default="false"/>

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

<xsd:attribute name="min" type="xsd:unsignedInt" use="optional" default="0"/>

<xsd:attribute name="multiSel" type="xsd:string" use="optional"/>

<xsd:attribute name="noThreeD" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="noThreeD2" type="xsd:boolean" use="optional" default="false"/>

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

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

<xsd:attribute name="seltype" type="ST_SelType" use="optional" default="single"/>

<xsd:attribute name="textHAlign" type="ST_TextHAlign" use="optional" default="left"/>

<xsd:attribute name="textVAlign" type="ST_TextVAlign" use="optional" default="top"/>

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

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

<xsd:attribute name="editVal" type="ST_EditValidation" use="optional"/>

<xsd:attribute name="multiLine" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="verticalBar" type="xsd:boolean" use="optional" default="false"/>

<xsd:attribute name="passwordEdit" type="xsd:boolean" use="optional" default="false"/>

</xsd:complexType>

See section 5.4 for the full W3C XML Schema ([XMLSCHEMA1] section 2.1).

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show: