Harbour Reference Guide

 

LEN()

Returns size of a string or size of an array.

Syntax

LEN( <cString> | <aArray> ) --> <nLength>

Arguments

<acString> is a character string or the array to check.

Returns

The length of the string or the number of elements that contains an array.

Description

This function returns the string length or the size of an array. If it is used with a multidimensional array it returns the size of the first dimension.
Examples
      ? Len( "Harbour" ) --> 7
      ? Len( { "One", "Two" } ) --> 2
Tests
      function Test()
         LOCAL cName := ""
         ACCEPT "Enter your name: " TO cName
         ? Len( cName )
      return nil
Status

Ready

Compliance

LEN() is fully CA-Clipper compliant.

Files

Library is rtl

See Also

 




[Source Forge]

Other Docs Categories

Advantage Database RDD
Array
Binary conversion
Classes
Code Block
Console input
Conversion
Conversion Tools
DOS
Data input and output
Database
Database Tools
Date
Dos Tools
Environment
Error recovery
Events
File management
GT
Harbour Tools
Internal
Low Level
Math
Misc
Miscellaneous
Nation
Object manipulation
Operating System Specific
Parameter Checks
String Tools
Strings
TBrowse Method
TBrowse class
Terminal
Time
Utility
Variable Management

 

Last updated on 2001/07/30