suhr
10-31-2012, 07:09 AM
Hi, i am trying to get the date from the emails in Lotus notes.
I can connect and get a lot of informations already but cant get the date of the email. Any help?
Sub MailScan()
Dim noSession As Object
Dim noDatabase As Object
Dim noView As Object
Dim noDocument As Object
Dim noNextDocument As Object
Dim i As Integer
'Embedded objects are of the datatype Variant.
Dim vaItem As Variant
Dim vaAttachment As Variant
Dim aux2 As String
Dim aux As String
'Instantiate the Notes session.
Set noSession = CreateObject("Notes.NotesSession")
'Instantiate the actual Notes database.
'(Here is the personal e-mail database used and since it's a
'local database no reference is made to any server.)
Set noDatabase = noSession.GETDATABASE("xxx", "xxx")
'Folders are views in Lotus Notes and in this example the Inbox is used.
Set noView = noDatabase.GetView("($Inbox)")
'Get the first document in the defined view.
Set noDocument = noView.GetFirstDocument
aux = noDocument.GetItemValue("Subject")(0)
I can get the Subject as You can see in the last line.
Any help would be apreciated.
I can connect and get a lot of informations already but cant get the date of the email. Any help?
Sub MailScan()
Dim noSession As Object
Dim noDatabase As Object
Dim noView As Object
Dim noDocument As Object
Dim noNextDocument As Object
Dim i As Integer
'Embedded objects are of the datatype Variant.
Dim vaItem As Variant
Dim vaAttachment As Variant
Dim aux2 As String
Dim aux As String
'Instantiate the Notes session.
Set noSession = CreateObject("Notes.NotesSession")
'Instantiate the actual Notes database.
'(Here is the personal e-mail database used and since it's a
'local database no reference is made to any server.)
Set noDatabase = noSession.GETDATABASE("xxx", "xxx")
'Folders are views in Lotus Notes and in this example the Inbox is used.
Set noView = noDatabase.GetView("($Inbox)")
'Get the first document in the defined view.
Set noDocument = noView.GetFirstDocument
aux = noDocument.GetItemValue("Subject")(0)
I can get the Subject as You can see in the last line.
Any help would be apreciated.