Text control

The Text control is a simple text box that can accept arbitrary input, and has the following properties:

Identifier. The unique identifier for the control. This is the identifier to use when referencing the control in the syntax template.

Title. An optional title that appears with the control. For multi-line titles or long titles, click the ellipsis (...) button and enter your title in the Title Property dialog.

Title Position. Specifies the position of the title relative to the control. Values are Top and Left where Top is the default.

ToolTip. Optional ToolTip text that appears when the user hovers over the control.

Mnemonic Key. An optional character in the title to use as a keyboard shortcut to the control. The character appears underlined in the title. The shortcut is activated by pressing Alt+[mnemonic key]. The Mnemonic Key property is not supported on Mac.

Text Content. Specifies the allowed contents. The value Any specifies that the contents are arbitrary. The value Variable Name specifies that the text box must contain a string that adheres to rules for IBM® SPSS® Statistics variable names. See the topic Variable names for more information. The value New dataset name specifies that the text box must contain a valid IBM SPSS Statistics dataset name and cannot be the name of a currently open dataset.

Default Value. The default contents of the text box.

Width. Specifies the width of the text area of the control in characters. The allowed values are positive integers. An empty value means that the width is automatically determined.

Required for execution. Specifies whether a value is required in this control in order for execution to proceed. If True is specified, the OK and Paste buttons will be disabled until a value is specified for this control. If False is specified, the absence of a value in this control has no effect on the state of the OK and Paste buttons. The default is False.

Syntax. Specifies the command syntax that is generated by this control at run time and can be inserted in the syntax template.

  • You can specify any valid command syntax. For multi-line syntax or long syntax, click the ellipsis (...) button and enter your syntax in the Syntax Property dialog.
  • The value %%ThisValue%% specifies the run time value of the control, which is the content of the text box. This is the default.
  • If the Syntax property includes %%ThisValue%% and the run time value of the text box is empty, then the text box control does not generate any command syntax.
Quote Handling. Specifies handling of quotation marks in the run time value of %%ThisValue%% when the Syntax property contains %%ThisValue%% as part of a quoted string. In this context, a quoted string is a string that is enclosed in single quotation marks or double quotation marks. Quote handling applies only to quotation marks that are the same type as the quotation marks that enclose %%ThisValue%%. The following types of quote handling are available.
Syntax
Quotation marks in the run time value of %%ThisValue%% that match the enclosing quotation marks are doubled. For example, if the Syntax property is'%%ThisValue%%' and the run time value of the text control is Text box's value, then the generated syntax is 'Text box''s value'.
Python
Quotation marks in the run time value of %%ThisValue%% that match the enclosing quotation marks are escaped with the backslash character (\). For example, if the Syntax property is '%%ThisValue%%' and the run time value of the text control is Text box's value, then the generated syntax is 'Text box\'s value'. Quote handling is not done when %%ThisValue%% is enclosed in triple quotation marks.
R
Quotation marks in the run time value of %%ThisValue%% that match the enclosing quotation marks are escaped with the backslash character (\). For example, if the Syntax property is '%%ThisValue%%' and the run time value of the text control is Text box's value, then the generated syntax is 'Text box\'s value'.
None
Quotation marks in the run time value of %%ThisValue%% that match the enclosing quotation marks are retained with no modification.

Enabling Rule. Specifies a rule that determines when the current control is enabled. Click the ellipsis (...) button to open the Enabling Rule dialog box and specify the rule. The Enabling Rule property is visible only when other controls that can be used to specify an enabling rule exist on the canvas.