On Aug 21, 9:45Â am, "Michael Bauer [MVP - Outlook]" <
[email protected]>
wrote:
Use the ItemAdd or NewMailEx events of the Inbox. If you want to getthe
received time, read the ReceivedTime property.
Add a reference to the Excel library to your VBA project. Use the
Workbooks.Open function to get a workbook, then Sheets and Range to work
with sheets and cells. See the object browser (f2) for more details of
what's exposed by the object model. And press f1 for help.
--
Best regards
Michael Bauer - MVP Outlook
 : Outlook Categories? Category Manager Is Your Tool
 : VBOffice Reporter for Data Analysis & Reporting
 : <
http://www.vboffice.net/product.html?pub=6〈=en>
Am Thu, 20 Aug 2009 22:32:02 -0700 (PDT) schrieb nitesh bansal:
Hi
is it possible to write a macro that extracts the date and time stamp
of an incoming message coming in the inbox folder and save those
stamps in an excel sheet in separate columns with another column
adding the subject of the mail, and then finally move such message to
a specific folder.
Thanks in advance,
Hi
I tried the following code
Sub TimeStampDigger()
  Dim i%, myItem As Outlook.MailItem
  Set myItem = Application.Session.GetDefaultFolder
(olFolderInbox).Items(1).Display
  myTime = myItem.ReceivedTime
End Sub
The 2nd line of the code gives an error. I can't figure out how to set
mailItem as Item or Item as mailItem. I am completely confused about
this.
Kindly help.
Thanks,