![]() | ![]() | ![]() | ![]() | ![]() |
ToLowerCase() |
This is a rexx function provided by PPWIZARD. This routine (like all PPWIZARD extensions) can be used with any operating system supported by PPWIZARD.
This function takes a single parameter and returns it in lower case. The translations are performed for english characters only (a-z), for other languages see the examples below.
Note that there is no PPWIZARD "upper case" case routine as the standard rexx translate() does this nicely.
Example - Polish Case Translation |
You could have the following in a header file (possibly called "polish.ih"):
;--- Define all non-english upper/lower case pairs -------------------------- #DefineRexx '' ;--- Polish characters in cp-1250 or iso-8859-2 encoding ----------------- PL_Lower = 'abcdefghijklmnopqrstuvwxyz' || 'B1B9E6EAB3F1F3B69CBFBC9F'x PL_Upper = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' || 'A1A5C6CAA3D1D3A68CAFAC8F'x #DefineRexx ;--- "$$" commands for Polish (cp-1250 or iso-8859-2 encoding) case conversion --- #DefineRexx REXX_$$PL_UPPER TheValue = translate(TheValue, PL_UPPER, PL_LOWER); #DefineRexx #DefineRexx REXX_$$PL_LOWER TheValue = translate(TheValue, PL_LOWER, PL_UPPER); #DefineRexx
Now for some examples of the above being used:
;--- Define something ---------------------------------------- #define SomethingInUpper ASDF ;--- Use previously defined value (required in lower case) --- This is in lower case: "<$SomethingInUpper $$PL_LOWER>" ;--- Use previously defined value (required in lower case) --- #DefineRexx '' LowerCaseValue = translate('FRED', PL_LOWER, PL_UPPER) #DefineRexx So is this: "<??LowerCaseValue>"
![]() | ![]() | ![]() | ![]() | ![]() |