String_Length

Get the number of characters in a string.

Parameters

String

The string whose length is to be determined.

Format

String_Length (String)

Return Value

Returns the number of characters in the string. Returns 0 if the string is empty (has no characters).

Example

Script( String_Length_Test )
String( strForLength )
String( strTitle )
Number( nStringLength )
Activate( From_Menu )
strForLength = Ask_String( "Enter a string", "String_Length", 1, 99, "abcde" )
nStringLength = String_Length( strForLength )
strTitle = String_Combine( "Length of """, strForLength )
strTitle = String_Combine( strTitle, """" )
Ask_OK( Number_To_String_Decimal( nStringLength ), strTitle )
Return

See Also

String_Find_First, String_Find_Last, String_Equal, String_Set

 


Was this article useful?    

The topic was:

Inaccurate

Incomplete

Not what I expected

Other

Privacy and Legal