Results 1 to 8 of 8

Thread: Solved: The sent date / time of an email

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Administrator
    VP-Knowledge Base
    VBAX Guru MOS MASTER's Avatar
    Joined
    Apr 2005
    Location
    Breda, The Netherlands
    Posts
    3,281
    Location
    Hi Michelle,

    The equivalent of "PR_CLIENT_SUBMIT_TIME" Killian spoke of in VBA of the mailitem object would be: ".SentOn"

    Like: oMailItem.SentOn

    But I also don't now how to retrieve all the data of servers where a mailitem has been since it was Send!

    At our company a single mailitem is routed to 6 different Internal Servers (World wide) because of policy and you can trace that if you mark it for trace.

    That data is probably what your looking for but I've got no clue where to get that data. The Redemption tip of Killian will probably work because Redemption exposes so much more then you can accomplish in VBA.

    Enjoy!
    _________
    Groetjes,

    Joost Verdaasdonk
    M.O.S. Master

    Mark your thread solved, when it has been, by hitting the Thread Tools dropdown at the top of the thread.
    (I don't answer questions asked through E-mail or PM's)

  2. #2
    Dear Killian and Mos Master,



    It don't interrest us over how many servers a mail is sent, the only thing what important is, that is the first time a mail is received by a server.


    Is there a posibillity to get this date/time?

    The MM is talking about: oMailItem.SentOn, what is that for a date/time? How can we get this?

    Nice regards & thanks for the help

    Michelle.

  3. #3
    Administrator
    VP-Knowledge Base
    VBAX Guru MOS MASTER's Avatar
    Joined
    Apr 2005
    Location
    Breda, The Netherlands
    Posts
    3,281
    Location
    Hi Michelle,

    If it's your server then use the ".ReceivedTime" property of the mailitem object. That's the time on which you received it. Just try it out.

    You ask me how to get the ".SentOn" property of the mailitem object. That's kinda strange to me. You've been programming for a longer time now in Outlook.

    Haven't you worked on email items (MailItem) before in Outlook?

    The MailItem object has to many properties to start explaining but
    this code will give you some:[VBA]
    Sub GetMailProps()
    Dim myMail As Outlook.MailItem
    For Each myMail In Application.ActiveExplorer.Selection
    MsgBox "Mail was sent on: " & myMail.SentOn & vbCr & _
    "by: " & myMail.SenderName & vbCr & _
    "message was received at: " & myMail.ReceivedTime
    Next

    Set myMail = Nothing
    End Sub
    [/VBA]
    Just select some Mailitems in your Inbox and run the sub.

    Enjoy!
    _________
    Groetjes,

    Joost Verdaasdonk
    M.O.S. Master

    Mark your thread solved, when it has been, by hitting the Thread Tools dropdown at the top of the thread.
    (I don't answer questions asked through E-mail or PM's)

  4. #4
    Hello Mos Master,

    Thanks for the information, you are great!

    Michelle.

  5. #5
    Administrator
    VP-Knowledge Base
    VBAX Guru MOS MASTER's Avatar
    Joined
    Apr 2005
    Location
    Breda, The Netherlands
    Posts
    3,281
    Location
    Quote Originally Posted by michelle
    Hello Mos Master,

    Thanks for the information, you are great!

    Michelle.
    You're most welcome..tnx to Killian as well!

    Ps..don't forget to mark the thread.
    _________
    Groetjes,

    Joost Verdaasdonk
    M.O.S. Master

    Mark your thread solved, when it has been, by hitting the Thread Tools dropdown at the top of the thread.
    (I don't answer questions asked through E-mail or PM's)

  6. #6
    Quote Originally Posted by MOS MASTER View Post
    Hi Michelle,

    If it's your server then use the ".ReceivedTime" property of the mailitem object. That's the time on which you received it. Just try it out.

    You ask me how to get the ".SentOn" property of the mailitem object. That's kinda strange to me. You've been programming for a longer time now in Outlook.

    Haven't you worked on email items (MailItem) before in Outlook?

    The MailItem object has to many properties to start explaining but
    this code will give you some:[VBA]
    Sub GetMailProps()
    Dim myMail As Outlook.MailItem
    For Each myMail In Application.ActiveExplorer.Selection
    MsgBox "Mail was sent on: " & myMail.SentOn & vbCr & _
    "by: " & myMail.SenderName & vbCr & _
    "message was received at: " & myMail.ReceivedTime
    Next

    Set myMail = Nothing
    End Sub
    [/VBA]
    Just select some Mailitems in your Inbox and run the sub.

    Enjoy!
    Thank you after 18yrs!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •