NAME

left$ - return leftmost part of string

SYNOPSIS

v$ = left$(StrExpr, NumExpr)

DESCRIPTION

Left$ returns a string composed of the leftmost characters of the string expression supplied as the first argument.  The second argument, NumExpr, specifies the length of the string to be returned. 

StrExpr may be any string expression.  NumExpr may be any numeric expression.  If the value of NumExpr is greater than the number of characters in StrExpr, all of StrExpr will be returned. 

EXAMPLE

The program
	a$ = "CLEVELAND, OHIO"
	b$ = left$(a$, 9)
	print b$
produces
	CLEVELAND
In this example, the left$ function is used to extract the first nine characters from the string "CLEVELAND, OHIO". 

SEE ALSO

right$, mid$(func)

DIAGNOSTICS

If NumExpr is less than 0, an "Illegal function call" error occurs. 

from The Basmark QuickBASIC Programmerís Manual by Lawrence Leinweber