Len Procedure

Returns the length of the string sStr.

Syntax

[ lLength = ] Len ( sStr )

The Len procedure syntax has the following parts:

Name

Type

Description

lLength

Long

Length of sStr

sStr

Val BString

Input string

Comments

This function returns the number of characters in the string sStr. This number can be equal to or less than the maximum defined bytes for that string (dimension). Nonprintable characters as well as spaces are counted.

Example

! s is defined as BString

s="ATEasy"

Print Len(s) ! will print 6

See Also

Left, Mid, Right, SetLen, String Data Types, String Literals