Right

Purpose

Returns a Variant (string) containing a specified number of characters from the right side of a string.

Syntax

Right(string, length)

Argument Description
string String expression from which characters are returned. If string contains Null, then Null is returned.
length Variant (Long). Numeric expression indicating how many characters to return. If 0, then a zero-length string ("") is returned. If greater than or equal to the number of characters in string, then the entire string is returned.
Note: To determine the number of characters in a string, use the Len function.

Description

Use the RightB function with byte data contained in a string. Instead of specifying the number of characters to return, length specifies the number of bytes.

Example

Function Result
Right("The characters on the right",12) "on the right"