Is there a way to remove all instances of "Re:" in a subject without having
to mark positions and do the "4 thru -1" type of calculations?


on 11/1/04 1:59 AM, Paul Berkowitz <[EMAIL PROTECTED]> wrote:

> repeat with theMsg in (get current messages)
>     set theSubject to subject of theMsg
>     if theSubject starts with "Re:" or theSubject starts with " Re:" then
>         try
>             if theSubject starts with "Re:" then
>                 set theSubject to text 4 thru -1 of theSubject
>             else if theSubject starts with " Re:" then
>                 set theSubject to text 5 thru -1 of theSubject
>             end if
>             repeat while theSubject  starts with " "
>                 set theSubject to text 2 thru -1 of theSubject
>             end repeat
>         on error -- <no subject>
>             set theSubject  to ""
>         end try
>  
>         set subject of theMsg to theSubject
> 
>     end if
> end repeat


-- 
To unsubscribe:                     
<mailto:[EMAIL PROTECTED]>
archives:       
<http://www.mail-archive.com/entourage-talk%40lists.letterrip.com/>
old-archive:       
<http://www.mail-archive.com/entourage-talk%40lists.boingo.com/>

Reply via email to