Y_YA_ChangeCase
Functionality to convert the InputString to an OutputString after modifying the characters to be lower case, upper case, or title case. Title case mode will capitalize the first letter of each word.
Parameters
| * | Parameter | Data Type | Description | Default |
|---|---|---|---|---|
| VAR_INPUT | ||||
| B | Enable | BOOL | The function block will continue to execute every scan while Enable is TRUE and there are no errors. | FALSE |
| V | CaseType | INT | Enumeration to choose the conversion type. Select 0 for lower case, 1 for UPPER CASE, and 2 for Title Case. Title Case will capitalize the first letter of each word. Enumerations values can also be used. (YTB_CaseType#Lower, YTB_CaseType#Upper, YTB_CaseType#Title) | INT#0 (YTB_CaseType#Lower) |
| V | InputString | STRING | The String to be modified | '' |
| VAR_OUTPUT | ||||
| B | Valid | BOOL | The Valid output indicates that the function block is operating normally and the outputs of the function block are valid. | |
| V | OutputString | STRING | Modified output of the string that was input to the function block | |
Notes
- Enable must be set high for this function to operate.
- The OutputString is only valid if Valid is high. If for some reason the conversion had an error, Valid will not be TRUE.