Re: compactness of expression question
Re: compactness of expression question
- Subject: Re: compactness of expression question
- From: billp <email@hidden>
- Date: Thu, 17 Jan 2002 15:44:13 -0600
Steven,
Thanks for the solution. I am up against my 32k limit in ScriptEditor
so every character counts now. The reason I set each global inside
the various if statements before was to not cause AS to set a global
for something it may not have measured. I was thinking it was more
efficient memory-wise.
Bill
>
2. adding one global line:
>
>
----
>
>
global CharacterCount, WordCount, LineCount, ParagraphCount, TableCount
>
>
if ItemKind = "Characters" then
>
set CharacterCount to ItemCount
>
else if ItemKind = "Words" then
>
set WordCount to ItemCount
>
else if ItemKind = "Lines" then
>
set LineCount to ItemCount as integer
>
else if ItemKind = "Paragraphs" then
>
set ParagraphCount to ItemCount as integer
>
else if ItemKind = "Tables" then
>
set TableCount to ItemCount
>
end if