A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Time Stamp on Messages



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old January 7th 09, 12:31 AM posted to microsoft.public.outlook.program_vba
Bob Smith
external usenet poster
 
Posts: 34
Default Time Stamp on Messages

I appear to be missing something with relation to timezones.

I am using CDO to connect to two seperate mailboxes. When I send a message
to both of these mailboxes at the same time, the result I get for
oMessage.TimeReceived are different by a factor of 7 hours. The strange thing
is, I checked in outlook, the received time looks correct for both. I also
checked under ToolsOptionsCalender OptionsTime Zone. They are both set to
Mountain Standard.

Since the script is running on the same machine to connect to these two
mailboxes I have ruled out any regional time settings on the local client. Is
there somewhere else timezone information is stored for the mailbox? Both
mailboxes are on the same exchange server also.


  #2  
Old January 7th 09, 12:43 AM posted to microsoft.public.outlook.program_vba
Dmitry Streblechenko
external usenet poster
 
Posts: 2,116
Default Time Stamp on Messages

How and when doyou read the property? It is supposed to be stored in the UTC
timezone. Outlook UI and CDO 1.21 (through the Message.ReceivedTime
property) convert the value to teh local timezone.

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"Bob Smith" wrote in message
...
I appear to be missing something with relation to timezones.

I am using CDO to connect to two seperate mailboxes. When I send a message
to both of these mailboxes at the same time, the result I get for
oMessage.TimeReceived are different by a factor of 7 hours. The strange
thing
is, I checked in outlook, the received time looks correct for both. I also
checked under ToolsOptionsCalender OptionsTime Zone. They are both set
to
Mountain Standard.

Since the script is running on the same machine to connect to these two
mailboxes I have ruled out any regional time settings on the local client.
Is
there somewhere else timezone information is stored for the mailbox? Both
mailboxes are on the same exchange server also.




  #3  
Old January 7th 09, 12:46 AM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Time Stamp on Messages

Is this CDO 1.21?

If so, the property for time zone may be incorrect. Use
Session.SetOption("TimeZone") to set the correct time zone.
The setting is stored on the user's mailbox, in property 0x7D020102 on the
inbox folder. The time zone is the first DWORD of the property value

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Bob Smith" wrote in message
...
I appear to be missing something with relation to timezones.

I am using CDO to connect to two seperate mailboxes. When I send a message
to both of these mailboxes at the same time, the result I get for
oMessage.TimeReceived are different by a factor of 7 hours. The strange
thing
is, I checked in outlook, the received time looks correct for both. I also
checked under ToolsOptionsCalender OptionsTime Zone. They are both set
to
Mountain Standard.

Since the script is running on the same machine to connect to these two
mailboxes I have ruled out any regional time settings on the local client.
Is
there somewhere else timezone information is stored for the mailbox? Both
mailboxes are on the same exchange server also.



  #4  
Old January 7th 09, 12:49 AM posted to microsoft.public.outlook.program_vba
Bob Smith
external usenet poster
 
Posts: 34
Default Time Stamp on Messages

I think I found the answer

objSession.GetOption("TimeZone") = 16386 on the mailbox that exhibits the
incorrect behaviour. Does anyone know what 15385 would be and how that would
be set on a mailbox. I know how to set it to 12 from a script, but would like
to know what would case this.


"Bob Smith" wrote:

I appear to be missing something with relation to timezones.

I am using CDO to connect to two seperate mailboxes. When I send a message
to both of these mailboxes at the same time, the result I get for
oMessage.TimeReceived are different by a factor of 7 hours. The strange thing
is, I checked in outlook, the received time looks correct for both. I also
checked under ToolsOptionsCalender OptionsTime Zone. They are both set to
Mountain Standard.

Since the script is running on the same machine to connect to these two
mailboxes I have ruled out any regional time settings on the local client. Is
there somewhere else timezone information is stored for the mailbox? Both
mailboxes are on the same exchange server also.


  #5  
Old January 7th 09, 03:07 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Time Stamp on Messages

Neither of those are valid time zone values. The maximum possible valid
value is CdoTmzMax = 52. Anything above that is invalid and caused by
corruption of some sort.

CDO uses the property value in the first DWORD of 0x7D020102 for the CDO
time zone. It can become corrupted if accesses are made from another time
zone, if the Windows time zone struct from the registry doesn't match the
MAPI time zone settings or for a number of other reasons. Outlook doesn't
use the CDO value, so it can be correct while the CDO values aren't.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Bob Smith" wrote in message
...
I think I found the answer

objSession.GetOption("TimeZone") = 16386 on the mailbox that exhibits the
incorrect behaviour. Does anyone know what 15385 would be and how that
would
be set on a mailbox. I know how to set it to 12 from a script, but would
like
to know what would case this.


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
how do I time stamp notes in contacts? Jerry Outlook - Using Contacts 1 November 29th 08 06:28 AM
Outlook 2000 time stamp swest23 Outlook - Installation 7 March 23rd 07 06:15 PM
date/time stamp Max Outlook Express 3 December 20th 06 12:04 AM
Wrong time stamp js1662 Outlook - Installation 2 May 15th 06 07:22 PM
Date/Time Stamp of Event Domenic Outlook - Calandaring 3 April 19th 06 04:33 AM


All times are GMT +1. The time now is 10:30 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.