Brilliant! Thanks guys I will have to have a play around later On 4 July 2010 04:12, Grant Edwards <inva...@invalid.invalid> wrote:
> > > I'm trying to write a simple script which displays the basic details > > of a person's mailbox. My problem is that it causes all the messages > > to be marked as read on the server, > > > > code, mailboxen= server.list() > > print mailboxen > > # if it's called INBOX, then… > > server.select("INBOX") > > You probably want to try examine() instead of select(). That opens > the mailbox in a read-only mode which and should avoid changing any > flag values. > > >From RFC3501: > > The EXAMINE command is identical to SELECT and returns the same > output; however, the selected mailbox is identified as > read-only. No changes to the permanent state of the mailbox, > including per-user state, are permitted; in particular, EXAMINE > MUST NOT cause messages to lose the \Recent flag. > > -- > Grant > > -- > http://mail.python.org/mailman/listinfo/python-list >
-- http://mail.python.org/mailman/listinfo/python-list