CALL "C$JUSTIFY" USING text alignment |
text | PIC X(n) | Specifies the text to be justified. |
alignment | PIC X(1) | It specifies a value representing the justification alignment. Valid values are: "L" Left justified. "C" Centered. "R" Right justified. |
working-storage section. 77 str1 pic x(10) value "hello". 77 ruler pic x(10) value "1234567890". ... procedure division. ... display ruler display str1 call "c$justify" using str1 "C" display str1 call "c$justify" using str1 "R" display str1 call "c$justify" using str1 "L" display str1. |