On 11/15/03 10:25 AM, Paul Berkowitz <[EMAIL PROTECTED]> wrote:

> On 11/15/03 7:59 AM, "Jeffrey Berman" <[EMAIL PROTECTED]> wrote:
> 
>> tell application "Microsoft Entourage" to �
>>     get folders of default mail account
>> DateMatch for result
> 
> That won't work if the default mail account is a POP account. In that case
> it doesn't have any folders. Just so you know. Probably you're just doing
> this for yourself and know that it will always be an IMAP account?

Thanks for the reminder about POP accounts.  Your hunch is correct that my
script was originally written for use only with an IMAP account.


> (In which case why not just hard-code it in?)

By using the "default mail account" term rather than a specific account
identifier, am I not allowing the script to work even if I change to a
different default (IMAP) account?


> Also you haven't set a variable (FolderList) to the result, so your handler
> has nothing to operate on.

I do not understand this comment.  In the above code, the DateMatch handler
operates on the result of the preceding get command, which it does just
fine.  Incorporating your comment about POP accounts in the following code
also works:

tell application "Microsoft Entourage"
    set MailAccount to default mail account
    if class of MailAccount is not POP account then
        get folders of MailAccount
    else
        get folders
    end if
end tell

DateMatch for result


-Jeff Berman

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