Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Confused???

From: nitsch-lists::netcologne::de at: 14-Jul-2002 23:05

Am Sonntag, 14. Juli 2002 21:33 schrieb Ed Dana:
> I've created a small program to scan emails from my inbox. It works > fine until I try and remove them. Without the REMOVE command, it parses > all emails in the inbox. Once I add the REMOVE command, it takes several > passes to get everything cleared out. > > The script looks like this: > Inbox: Open Load %Mailbox.r > Print [ Length? Inbox "messages on server." ] > > ForAll Inbox [ > Mail: Import-email First Inbox > Print [ Index? Inbox Mail/Subject ] > Remove Inbox > ]
(not tested) while[not empty? Inbox] [ Mail: Import-email First Inbox Print [ Index? Inbox Mail/Subject ] Remove Inbox ] if you don't want to remove everything while[not empty? series][ either i-want-to-keep-it[ series: next series ][ remove series ] ]
> close inbox > > The results look like this: > >> do %Test.r > > 5 messages on server. > 1 And now, a massage from the Swedish Prime Minister! > 2 She sells sea shells by the sea shore. > 3 And now, for something completely different! > > >> do %Test.r > > 2 messages on server. > 1 Ask not what you can do for your country! > > >> do %Test.r > > 1 messages on server. > 1 Inna gadda davida, baby! > > >> do %Test.r > > 0 messages on server. > > Even if I wait five minutes, It still does this, so it's not a latency > issue. > > What gives? Am I missing the obvious?
-Volker