len()

Syntax
long len( string_expr )


Description
This returns the number of characters in string_expr. For strings declared as FIXED, the total length of the string is returned. For non-fixed strings, the current length is returned. To retrieve the length of FIXED strings, excluding trailing spaces, use strip$(). 


Example
long      lng
string    var(20)
string    fix(20)    fixed
var = "abc"
fix = "abc"
lng = len( var )                | Returns 3
lng = len( fix )                 | Returns 20
lng = len( strip$(fix) )     | Returns 3


Related Post:

People who read this post also read :



0 comments:

Post a Comment

Share

Twitter Delicious Facebook Digg Stumbleupon Favorites More