How do I Create a Custom Property, part 19,214,651

Ken Ray kray at sonsothunder.com
Thu Apr 22 13:51:12 EDT 2004


>> The line count will always be the number of return characters + 1, as
>> it is assumed that there is data both before and after a return 
>> character .
>
> On 4/22/04 8:53 AM, Thomas McGrath III wrote:
> 
> > Is this true?
> 
> There's an exception for a one-line string with a trailing 
> return. I.e.:
> 
>   this is line one <CR>
> 
> Which returns "1" as the number of lines.

Sorry, Tom, that's not true. If you end a string with a delimiter, you get
the same number of lines (or items if you use ",") as if you hadn't included
the delimiter.

Example:

  put the number of lines of ("Hello"&cr&"Goodbye"&cr)

--> 2

  put the number of items of "Ken,Tom,Dar,"

--> 3

HTH,

Ken Ray
Sons of Thunder Software
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/





More information about the use-livecode mailing list