String user input
- Last UpdatedJul 26, 2024
- 2 minute read
You should use either EchoEnabled or EchoMode, but not both. EchoMode allows you to specify the password mode, whereas the EchoEnabled allows only the states enabled or disabled.
You use the Echo Character element to control how user input is shown during run time. Possible values are Yes, No, and Password.
-
If the element is set to Yes, then during run time the string characters are shown in the input edit box. Input can only be enabled. Password character and encryption are disabled.
-
If the element is set to No, then during run time the input characters are not shown in the input edit box. Input can only be enabled. Password character and encryption are disabled.
-
If the element is set to Password, then during run time the password character is shown instead of the password typed by the user. A password character is optional, but if specified, cannot be empty. The default password character is an asterisk. Encryption is optional and is off by default. Input only is mandatory and is forced on.
If the elements do not match these criteria, then default options are used.
You can specify the following elements for a string user input animation link.
|
Elements |
Description |
|---|---|
|
Title |
Object name. Optional. |
|
Message |
Message text to user. Required if optional schema is used. Default is no message text. |
|
InputOnly |
If input only: {true, false}. Default is false. |
|
EchoCharacters |
Echo characters: no, yes, password. Required if optional schema is used. Default is yes. |
|
KeyPadEnabled |
If keypad is visible: true, false. Default is false. |
|
PasswordCharacter |
Password character. Default is "*" |
|
EncryptEnabled |
Encryption enabled: yes, no. Default is no. |
|
KeyAssignment |
Virtual key element, empty string, or absent. Default is no assignment. Empty string means no assignment occurs. |
|
Expression |
Message-type tag. Required. Object is not created if invalid or missing. |
Example:
<UserInputString>
<Title>UserInputString1</Title>
<InputOnly>false</InputOnly>
<KeyAssignment>
<KeyCode>F1</KeyCode>
<KeyFlags>Ctrl</KeyFlags>
</KeyAssignment>
<Message>Select Pump</Message>
<Expression>mTag001</Expression>
<EchoCharacters>true</EchoCharacters>
<EncryptEnabled>false</EncryptEnabled>
<PasswordCharacter>*</PasswordCharacter>
</UserInputString>
Minimal example:
<UserInputString>
<Message>Select Pump</Message>
<Expression>mTag001</Expression>
<EchoCharacters>true</EchoCharacters>
</UserInputString>