On or near 6/26/02 11:32 AM, Judi Sohn at [EMAIL PROTECTED] observed:

> On 6/26/02 2:08 PM, "Allen Watson" <[EMAIL PROTECTED]> wrote:
> 
>> Just noticed on another list a note from Paul B saying delete does not work
>> with lists, and that�s a feature request. So, you will have to replace that
>> �delete� line above with:
>> 
>>   set msgList to every message in f where its time sent < twoDaysAgo
>>   repeat with m in msgList
>>       delete m
>>   end repeat
> 
> Really? Because I compiled and ran the script you originally posted and it
> worked!!!!! It moved 3668 items to the deleted Items folder and every folder
> in my "mailing lists" folder now has nothing older than 2 days ago. What
> difference would making the above change make? It took a while to run but
> that's probably because it worked on 3500+ messages the first time. I'll
> wait for your answer before committing this script to a schedule, but it
> works perfectly as far as I can tell.
> 
Well, I was just taking Paul's word as gospel truth! I didn't want to test
by deleting anything. Paul, apparently you CAN delete a list of messages
now. The original line, which I advised Judi to change, and which she says
worked (!), was

           delete (every message in f where its time sent < twoDaysAgo)
  
Hm. Wait. His later message explains this. He said:

> What doesn't work is
> 
>   set aList to (every anything whose something is whatever)
>   delete aList
> 
> You have to express it as an 'every object' (with or without whose or 'where
> its' clauses) - even though that does evaluate to a list - rather than first
> evaluating it to a list. Can't delete a list as such. Just one of those
> things...

So, my original script was fine, because it did not set a variable to the
list of message and then try "delete" on that list. It did the delete
straight out...
> I know nothing about AppleScript other than to copy and paste to a Script
> Editor window. Oh, and I knew enough to change where you had "lists" to
> "Mailing lists" since that's they way I had it in my setup. I really want to
> learn one of these days.
> 
I'm glad you had the foresight to do that.

> Thank you so much for doing this Allen, I can't tell you how much I
> appreciate it!

You're welcome.
-- 
My web page: <http://home.earthlink.net/~allenwatson/>
My scripts page: <http:homepage.mac.com/allenwatson>
Microsoft MVP for Mac Entourage/Word--<[EMAIL PROTECTED]>


--
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