Re: Get GMT or UTC from message

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Ken Slovak - [MVP - Outlook] (kenslovak_at_mvps.org)
Date: 04/07/04


Date: Wed, 7 Apr 2004 10:18:41 -0400

There are a couple of ways to do this. If you are using CDO 1.21 code you
can use the Session.GetOptions("TimeZone") method to get the time zone as a
Long value that corresponds to an enum defined for CDO.

The local time zone information is also stored in the Windows registry.
Take a look at this MS KB article, it has more information:
http://support.microsoft.com/support/kb/articles/q221/5/42.asp

-- 
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm
"Ryan" <rschnieber@5ninegroup.com> wrote in message
news:02D703E4-1D65-4967-9BAE-FD6A57D0C321@microsoft.com...
> I'm looking for a way to get the GMT or UTC time from an email message; or
possibly find the time zone from where the email was sent.
>
> I know how to get the "Sent Time" from the Outlook MAPI interface.  This
however is the time from the client machine the email was sent from or the
time from the Exchange server if they are connected to an Exchange Server
through Outlook.
>
> My first thought is find the GMT or UTC.  If that information is not
available I would then look for the time zone then use the DateAdd function
to find the GMT time.
>
> Any help with this would be greatly appreciated.
>


Relevant Pages

  • Re: MAPI Received Time 1 Hour Earlier Than Outlook 2003 Received T
    ... correct date/time in outlook but the wrong date/time using CDO. ... > Outlook and Windows use a registry value to determine the user's time zone. ...
    (microsoft.public.outlook.program_vba)
  • Re: Time Zone issue with events
    ... If your Exchange server is located in a different time zone than you are, ... When I create an event in Entourage it appears correctly in outlook. ...
    (microsoft.public.mac.office.entourage)
  • Re: MAPI Received Time 1 Hour Earlier Than Outlook 2003 Received T
    ... with CDO there can be a disconnect between your Windows and Outlook settings and what CDO is doing. ... Outlook and Windows use a registry value to determine the user's time zone. ... Then when you get a date using the Outlook object model that local time zone is used to convert the stored GMT values to local time. ...
    (microsoft.public.outlook.program_vba)
  • Re: Clock ALWAYS an hour behind on startup
    ... I knew he was using CDO (Microsoft's inscrutable name for the Web-based ... interface), but never noticed before that ALL those posts use Redmond time. ... Microsoft Windows MVP ... | That -0700 indicates that you have not changed your time zone from the ...
    (microsoft.public.windowsxp.general)
  • Re: Importing problem
    ... You need to check both time zone and daylight saving time settings in both ... Windows and Outlook. ... > the exchange server from Outlook running on my PC. ...
    (microsoft.public.outlook)