Hide deleted IMAP messages?

P

Peter Weil

Does anyone know whether it is possible to access Entourage X's mail
preference for hiding or showing deleted IMAP messages via AppleScript? I
would like to be able to toggle this quickly. And if this preference can be
controlled via AppleScript, can it be applied to particular custom views or
browser windows?

TIA, Peter
 
P

Paul Berkowitz

Does anyone know whether it is possible to access Entourage X's mail
preference for hiding or showing deleted IMAP messages via AppleScript? I
would like to be able to toggle this quickly. And if this preference can be
controlled via AppleScript, can it be applied to particular custom views or
browser windows?

No, there's no such AppleScript property or command. There is an 'IMAP
deleted items folder' to indicate which folder has been set up, but that's
it. (And I've have to check whether that "turns itself off" if you have
chosen not to have such a folder, as you seem to have done done.)

In fact, I'm sure exactly which preference you mean by "hide or show". There
is an account-wide preference in Advanced options of each IMAP account to
Move deleted messages to Deleted Items Folder, or to Mark messages as
deleted. Is that what you mean? In that case, you may be in luck. If you
have an IMAP Deleted Items Folder set up, then the AppleScript command

set (move messages to the IMAP deleted items folder) of IMAP account 1
to true

would "hide" deleted messages by moving them to the Deleted folder, and

set (move messages to the IMAP deleted items folder) of IMAP account 1
to false

would make newly deleted messages visible and marked for deletion. It
wouldn't move already-deleted messages back to the INBOX as marked for
deletion, mind you. It doesn't do that in the UI either. It would just apply
to future deletions.

I don't see any UI option to hide or show deleted IMAP messages. Am I
missing some option? Where do you do this? There IS an option to hide or
show READ messages, and that's very easy to reset in any browser folder or
custom view by using the keyboard shortcut cmd-shift-O. (It can't be done by
script.) Generally speaking, Entourage's AppleScripting doesn't concern
itself with UI views. Although it might be possible to do it in Panther with
so-called GUI scripting, that would only apply if there were a
straightforward menu item for doing the same thing. And I don't see any menu
item for doing this at all. So unless I'm misunderstanding, I think you're
out of luck.

Maybe you'd be better off simply setting up - or subscribing to (you may
have one already) - a Deleted Items folder on yoru IMAP server and using
that for deleted messages with the Advanced account setting. (Subscribe to
an existing Deleted Items folder by clicking on the IMAP server icon in your
Folder pane, clicking on the folder if you see it in the main window, and
click Subscribe. If you don't seen one there, you can make one then and
there by clicking New button and choose Folder.) Then set it up in Advanced
panel of the IMAP account as the Deleted Items folder, and select the radio
button to use it. Now just go to that folder to see your deleted messages,
and you won;t be bothered by them in your INBOX or other folders.

--
Paul Berkowitz
MVP Entourage
Entourage FAQ Page: <http://www.entourage.mvps.org/toc.html>
AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>

Please "Reply To Newsgroup" to reply to this message. Emails will be
ignored.

PLEASE always state which version of Entourage you are using - 2001 or X.
It's often impossible to answer your questions otherwise.
 
P

Peter Weil

I don't see any UI option to hide or show deleted IMAP messages. Am I
missing some option? Where do you do this?

See Mail and News Preferences, "Read" tab: IMAP: "Hide IMAP messages marked
for deletion"

What this does is allow the user to leave messages marked for deletion
(i.e., messages that have the "deleted" IMAP flag turned on and are waiting
to be "purged" or "expunged.") to be either visible with a "crossed -out"
style or left invisible.

This is sort of a "purer" way of handling IMAP messages and mailboxes.
Unlike POP, IMAP messages are marked for deletion and left within their own
mailboxes, and are removed when the mailbox is purged or expunged. Moving
such messages to a special Deleted Items folder seems like a way to make
IMAP appear to treat deletions in the same, familiar, "user-friendly" way
that POP does (even though it doesn't).

One could debate the pros and cons of this, but Entourage does at least give
you a choice. I prefer the "purer" IMAP method (others may prefer to
characterize this differently). But what I would like is to be able to
quickly toggle between hiding and showing messages marked for deletion.

Are the News and Mail Preferences in Entourage at all AppleScriptable?

-pw
 
P

Paul Berkowitz

See Mail and News Preferences, "Read" tab: IMAP: "Hide IMAP messages marked
for deletion"

What this does is allow the user to leave messages marked for deletion
(i.e., messages that have the "deleted" IMAP flag turned on and are waiting
to be "purged" or "expunged.") to be either visible with a "crossed -out"
style or left invisible.

This is sort of a "purer" way of handling IMAP messages and mailboxes.
Unlike POP, IMAP messages are marked for deletion and left within their own
mailboxes, and are removed when the mailbox is purged or expunged. Moving
such messages to a special Deleted Items folder seems like a way to make
IMAP appear to treat deletions in the same, familiar, "user-friendly" way
that POP does (even though it doesn't).

One could debate the pros and cons of this, but Entourage does at least give
you a choice. I prefer the "purer" IMAP method (others may prefer to
characterize this differently). But what I would like is to be able to
quickly toggle between hiding and showing messages marked for deletion.

Are the News and Mail Preferences in Entourage at all AppleScriptable?

No. You can set most of them on an item-by-item basis as needed. Entourage's
AppleScripting, like that of most applications, is not really for how to
make things look in the User Interface but rather how to automate or
customize am actual activity - doing something. Many, but not all, of the
choices in the prefs can be set by script for the particular job you want to
do.

There's also something in Panther called GUI scripting, available for
"assistive device access" in apps that support it. It tends to be not
perfectly reliable and somewhat clunky. And in Entourage it only seems to
work on menu items, not on buttons, checkmarks or other controls. So it
could open the Mail & News Preferences for you but not switch to Read page
nor check or uncheck that checkbox.



--
Paul Berkowitz
MVP Entourage
Entourage FAQ Page: <http://www.entourage.mvps.org/toc.html>
AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>

Please "Reply To Newsgroup" to reply to this message. Emails will be
ignored.

PLEASE always state which version of Entourage you are using - 2001 or X.
It's often impossible to answer your questions otherwise.
 
P

Peter Weil

On 1/25/04 10:06 PM, in article BC39D260.529B3%berkowit@spoof_silcom.com,

Ok, thanks Paul. I did find a better workaround for this using Keyboard
Maestro. Certainly not the most elegant method for a UNIX system -- it
reminds me more of QuickKeys macros under OS 9 -- but it does work.

I have one more question on this, if I may: can you tell me in which file(s)
Entourage stores its News and Mail Preferences?

Thanks for all of your AppleScripts and your work in helping to support
Entourage.

-pw
 
P

Paul Berkowitz

I suppose it could be in the Entourage Settings (10) file in
~/Library/Preferences/Microsoft/, but that's not going to do you any good.
It just shows up as blank in a text editor.

--
Paul Berkowitz
MVP Entourage
Entourage FAQ Page: <http://www.entourage.mvps.org/toc.html>
AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>

Please "Reply To Newsgroup" to reply to this message. Emails will be
ignored.

PLEASE always state which version of Entourage you are using - 2001 or X.
It's often impossible to answer your questions otherwise.
 
Top