pad end

This block is part of the number group and was last modified in core v14.0.1.

pad end v14.0.1

Pads the given number with char. on the right to match the given length.

In pins 3
  • number required
    number
  • length required
    number
  • char
    value

    Default 0

Out pins 1
  • value
    value

    Returns the padded number as value

Outputs the number pin as a string, right-padded with the char pin until it reaches length characters; values already at or above length pass through unchanged. The number is stringified as-is without numeric validation (nil becomes "0"), char defaults to "0", and an empty char pads with spaces. Example: number=42 length=5 char="0" -> "42000".

rpad

A typical wiring for pad end: number feeds the length pin; the value out pin feeds convert to uppercase.

Studio canvas example for the pad end block: typical wiring for pad end.

Version history

Introduced in v14.0.1.


Back to number Return to the main group to view all sub-groups Back to value: actions Return to the group to view all blocks within this group