Title: Re: Fix Received Dates...
On or near 2/20/01 8:02 PM, Joshua Jabbour at [EMAIL PROTECTED] observed:
> I was wondering if there was anyway of fixing the dates shown in Entourage
> as the "Received" Date. I just switched to IMAP mail from POP, and to
> transfer my messages, I just dragged them from my local folders to the
> server folders.
>
> The problem here is that they all have bad received dates (or should I say
> inaccurate?). The received dates show up as the last few days (when I moved
> the messages). The headers still show the correct date in the "received"
> path, and the sent dates in Entourage are still correct.
>
> Is there a simple way to fix all these messages to their original received
> dates, either via AppleScript or some other method (I found Allen's script
> to manually do it, but that doesn’t seem fun).
It should be fairly possible to modify my script to use the received header date. Instead of the display dialog statement to get the desired date, substitute code that finds the appropriate header and extracts the date.
Hm, just took a quick look; it isn't as easy as it sounds. There are multiple "Received:" headers, and there is the problem of adjusting for time zones. You'd need some calculations like this:
--Needs "Date Calculations" and "Akua Sweets" scripting additions
set t to "Wednesday, February 21, 2001 4:52:12 PM -0500"
-- Extract the offset number at end; assume whole hours (true for most time zones)
set minusGMT to ((text -5 thru -1 of t) as number) / 100
set GMToffset to minusGMT * 3600 -- Sender's offset from GMT
-- Get my current time zone
set {myGMT, DST} to time zone -- My offset from GMT
-- Extract the time sent from Received header
set sentTime to text 1 thru -7 of t -- Omit the " -nnnn" part
set sentTime to date sentTime
set sentGMT to (sentTime) - GMToffset -- Adjust to GMT
set sentTime to sentGMT + myGMT -- Adjust from GMT to local time
-- date "Wednesday, February 21, 2001 1:52:12 PM"
That just handles the date calculation part; the rest is up to you.
>
> Any direction would be greatly appreciated!
> thanks
> joshua
>
--
Peace,
Allen Watson <[EMAIL PROTECTED]> XNS name: =Allen Watson
A Mac family since 1984 <http://home.earthlink.net/~allenwatson/>
Applescripts for Outlook Express and Entourage: <http://homepage.mac.com/allenwatson/>
- Fix Received Dates... Joshua Jabbour
- Re: Fix Received Dates... Steve Sell
- Allen Watson
