Purpose |
Return a
|
Syntax |
result_var = CSET$(string_expression, strlen& [USING ustring_expression]) |
Remarks |
CSET$ centers the string string_expression into a string of strlen& characters. |
USING |
If ustring_expression is null (empty) or is not specified, CSET$ pads string_expression with space characters. Otherwise, CSET$ pads the string with the first character of ustring_expression. If string_expression is shorter then strlen&, CSET$ centers string_expression within result_var, padding both sides as described above; otherwise, CSET$ returns the left-most strlen& bytes of string_expression. |
See also |
CSET, GET, LET, LSET, LSET$, PUT, RESET, RSET, RSET$, STRINSERT$, TYPE SET |
Example |
a$ = CSET$("PowerBASIC", 20) ' result: " PowerBASIC "
a$ = CSET$("PowerBASIC",20 USING "*") ' result: "*****PowerBASIC*****" |