Sub GetFromInbox()
Dim olApp As Outlook.Application
Dim olNS As Namespace
Dim fldr As MAPIFolder
Dim olMail As Variant
Dim i As Integer
Dim MyName
Dim MyTime
Set olApp = New Outlook.Application
Set olNS = olApp.GetNamespace("MAPI")
Set fldr = olNS.GetSharedDefaultFolder(olFoldersSupport, Mailbox) .Folders("Inbox")
For Each olMail In fldr.Items
If olMail.Subject = "confirmation the reports)" Then
'ActiveSheet.Cells(i, 1).Value = olMail.Subject
MyName = olMail.To
MyTime = olMail.ReceivedTime
Sheets("Sheet1").Activate
With ActiveSheet.Range("C6:C50")
Set c = .Find(MyName, LookIn:=xlValues)
If Not c Is Nothing Then
Cells(c.Row, 6).Value = MyTime
End If
End With
End If
i = i + 1
Next olMail
Set fldr = Nothing
Set olNS = Nothing
Set olApp = Nothing
End Sub]