right_return_right_justified_string_.htm
Navigation: Language Reference > 13 - Built-in Functions >====== RIGHT (return right justified string) ====== | ![]() ![]() ![]() |
RIGHT(string [,length])
RIGHT | Right justifies a string. |
string | A string constant, variable, or expression. |
length | A numeric constant, variable, or expression for the length of the return string. If omitted, the length is set to the length of the string. |
The RIGHT procedure returns a right justified string. Trailing spaces are removed, then the string is right justified and returned with leading spaces.
Return Data Type: STRING
Examples:
!****************** RIGHT('ABC ') returns ' ABC' !****************** Message = RIGHT(Message) !Right justify the message !****************** IF FILEDIALOG('Pick file',FileName) CASE UPPER(RIGHT(FileName,4)) OF '.TPS' ; DO TPS_File OF '.DBF' ; DO DBase_File OF '.CSV' ; DO Text_File ELSE MESSAGE('Unknown file type ' & RIGHT(FileName,4)) END END !****************** MESSAGE('Confirm Credit Card Numbers Ends with ' & RIGHT(CardNo,4))
See Also:
right_return_right_justified_string_.htm.txt · Last modified: 2025/05/26 08:01 by carlbarnes