VBScript Right
Function
The Right function returns a specified number of characters from the right side of a string.
Tip: Use the Len function to determine the number of characters in a string.
Tip: See the Left function.
Syntax
Parameter | Description |
---|---|
string | Required. The string from which to return characters. |
length | Required. Specifies how many characters to return. If set to 0, it returns an empty string (""). If set to greater than or equal to the length of the string, it returns the entire string. |
Example 1
The above example outputs:
Example 2
Returns the entire string:
The above example outputs: