Pads the specified data on the right side to the given length.

Syntax

Smartsite SXML CopyCode image Copy Code
string string.pad(string data, string padding, integer minimumLength)
string string.pad(string data, string padding, integer minimumLength, boolean padLeft)

Parameters

Name Data Type Description
data String The original string.
padding String The padding that will be added.
minimumLength Integer The minimum length the output should be.
padLeft Boolean If true, that padding is added to the left side of the string, otherwise to the right side.

Return Value

Data Type Description
String

Expand image Example

SXML