The CvtCase procedure converts alphabetic characters to upper or lower case using a language-safe translation table.
varying-char-value CvtCase( szInputString 65535A Const Varying nOption 10I 0 Const Options(*NOPASS) |
| Symbolic Named Constant | Value | Description |
| CC_TOUPPER | 0 | Converts the input value to uppercase. |
| CC_TOLOWER | 1 | Converts the input value to lower case. |
If the function succeeds, the return value is the szInputString parameter's value converted to upper or lower case. If the function fails, no value is returned, that is the return value is and empty string, or blanks.
.....DName+++++++++++EUDS.......Length+TDc.Functions+++++++++++++++++++++++++
D Company S 50A Inz('Lunar Spacecraft Company')
D WrkName S 50A
.....CSRn01..............OpCode(ex)Extended-factor2++++++++++++++++++++++++++
C Eval WrkName = CvtCase(Company : CC_TOUPPER)
This procedure uses the OS/400 QlgConvertCase API to do the conversion using a language-safe translation table. It is called by the ToUpper and ToLower procedures to perform case conversion. ToUpper and ToLower are provided as external interfaces and should be used instead of CVTCASE. The interface to ToUpper and ToLower is fixed, whereas the call interface to CVTCASE may change on future releases.