Ah, Thanks for catching that Paul. The original script looked at the last received header (i.e. The earliest one), so there was no need to exit the loop. I added that mod in the message, but never tested it, and failed to spot the compound if...
-- Barry Wainwright Microsoft MVP (see http://mvp.support.microsoft.com for details) Seen the All-New Entourage Help Pages? - Check them out: <http://www.entourage.mvps.org/> > From: Paul Berkowitz <[EMAIL PROTECTED]> > Reply-To: "Entourage:mac Talk" <[EMAIL PROTECTED]> > Date: Wed, 21 Jul 2004 23:00:25 -0700 > To: Entourage Mac Talk <[EMAIL PROTECTED]> > Subject: Re: received message timing > > There's an error in Barry's script: > > repeat with aHeader in theHeaders > if aHeader starts with "Received:" then copy contents of aHeader > to receivedHeader > exit repeat > end repeat > > That should be: > > repeat with aHeader in theHeaders > if aHeader starts with "Received:" then > copy contents of aHeader to receivedHeader > exit repeat > end if > end repeat > > > The way it is now receivedHeader is being left at "" (blank) if the first > header doesn't happen to be "Received:" - many aren't. The theDate is also > "" and date theDate will error "invalid date and time". > > > -- > Paul Berkowitz > MVP MacOffice > Entourage FAQ Page: <http://www.entourage.mvps.org/faq/index.html> > AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/> > > PLEASE always state which version of Microsoft Office you are using - > **2004**, X or 2001. It's often impossible to answer your questions > otherwise. > > >> From: Hanagan <[EMAIL PROTECTED]> >> Reply-To: "Entourage:mac Talk" <[EMAIL PROTECTED]> >> Date: Wed, 21 Jul 2004 23:30:38 -0600 >> To: "Entourage:mac Talk" <[EMAIL PROTECTED]> >> Subject: Re: received message timing >> >> On 7/21/04 11:07 PM, Barry Wainwright wrote: >> >> Again, many thanks. >> >> I did as you instructed. Looked pretty straight forward once you get your >> head in there. >> >> After copying the script into the editor and compiling and saving and >> creating a new rule, when the rule is applied an Entourage error pops up >> that says: "Invalid Date and Time". Same thing happens when the script is >> run from Apple Script except it is now in AppleScript error. >> >> Any thoughts? >> >> ht >> >> >>> >>> Copy the script from the message window and paste it into a new script >>> window in Apple's 'Script Editor'. Save the script as a compiled script & >>> put it in the �Entourage Script Menu Items� folder in your �Microsoft User >>> Data� folder. The script can be manually run from the menu or called as an >>> action in a mail rule. >>> >>> >>> >>>> >>>> Thank you a bunch. >>>> >>>> ht >>>> P.S. >>>> You wouldn't happen to have one of those scripty things up your sleeve that >>>> will allow the toolbar to be customized/rearranged? Now THAT would be a >>>> veritable life saver!! ;-) >>> >>> Sorry, but that can't be done :( >>> >>>> >> >> -- >> 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/> >> >> > > > -- > 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/> > -- 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/>
