Len()

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 or the size of a hash table. 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

      PROCEDURE Test()
         LOCAL cName := ""
         ACCEPT "Enter your name: " TO cName
         ? LEN( cName )
         RETURN

Compliance

Clipper

Files

Library is rtl

Seealso

EMPTY(), RTRIM(), LTRIM(), AADD(), ASIZE()

Advertisements

3 responses to “Len()

  1. Pingback: Harbour All Function – L | Viva Clipper !

  2. Pingback: Harbour String Functions | Viva Clipper !

  3. Pingback: Harbour RG Summary | Viva Clipper !

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s