TextBoxActiveXControl class

TextBoxActiveXControl class

Represents a text box ActiveX control.

Inheritance: TextBoxActiveXControlActiveXControlActiveXControlBase

The TextBoxActiveXControl type exposes the following members:

Properties

PropertyDescription
workbookGets the ActiveXControlBase.workbook object.
typeGets the type of the ActiveX control.
widthGets and sets the width of the control in unit of points.
heightGets and sets the height of the control in unit of points.
mouse_iconGets and sets a custom icon to display as the mouse pointer for the control.
mouse_pointerGets and sets the type of icon displayed as the mouse pointer for the control.
fore_ole_colorGets and sets the ole color of the foreground.
back_ole_colorGets and sets the ole color of the background.
is_visibleIndicates whether this control is visible.
shadowIndicates whether to show a shadow.
linked_cellGets and sets the linked cell.
list_fill_rangeGets and sets the list fill range.
dataGets and sets the binary data of the control.
is_enabledIndicates whether the control can receive the focus and respond to user-generated events.
is_lockedIndicates whether data in the control is locked for editing.
is_transparentIndicates whether the control is transparent.
is_auto_sizeIndicates whether the control will automatically resize to display its entire contents.
ime_modeGets and sets the default run-time mode of the Input Method Editor for the control as it receives focus.
fontRepresents the font of the control.
text_alignRepresents how to align the text used by the control.
border_styleGets and set the type of border used by the control.
border_ole_colorGets and sets the ole color of the background.
special_effectGets and sets the special effect of the control.
max_lengthGets and sets the maximum number of characters
scroll_barsIndicates specifies whether the control has vertical scroll bars, horizontal scroll bars, both, or neither.
password_charGets and sets a character to be displayed in place of the characters entered.
is_editableIndicates whether the user can type into the control.
integral_heightIndicates whether the control will only show complete lines of text without showing any partial lines.
is_drag_behavior_enabledIndicates whether dragging and dropping is enabled for the control.
enter_key_behaviorSpecifies the behavior of the ENTER key.
True specifies that pressing ENTER will create a new line.
False specifies that pressing ENTER will move the focus to the next object in the tab order.
enter_field_behaviorSpecifies selection behavior when entering the control.
True specifies that the selection remains unchanged from last time the control was active.
False specifies that all the text in the control will be selected when entering the control.
tab_key_behaviorIndicates whether tab characters are allowed in the text of the control.
hide_selectionIndicates whether selected text in the control appears highlighted when the control does not have focus.
is_auto_tabIndicates whether the focus will automatically move to the next control when the user enters the maximum number of characters.
is_multi_lineIndicates whether the control can display more than one line of text.
is_auto_word_selectedSpecifies the basic unit used to extend a selection.
True specifies that the basic unit is a single character.
false specifies that the basic unit is a whole word.
is_word_wrappedIndicates whether the contents of the control automatically wrap at the end of a line.
textGets and set text of the control.
drop_button_styleSpecifies the symbol displayed on the drop button
show_drop_button_type_whenSpecifies the symbol displayed on the drop button

Example

from aspose import pycore
from aspose.cells import Workbook
from aspose.cells.drawing.activexcontrols import ControlType, TextBoxActiveXControl

# Initialize a new workbook.
book = Workbook()
# Add a TextBoxActiveXControl.
shape = book.worksheets[0].shapes.add_active_x_control(ControlType.TEXT_BOX, 1, 0, 1, 0, 100, 50)
activeXControl = pycore.cast(TextBoxActiveXControl, shape.active_x_control)
# do your business
# Save the excel file.
book.save("exmaple.xlsx")

See Also