task to send email from excel. The following is an example column. How can I get the email value from the loop? Thanks

Here is my code:
Dim rng as range
Dim row as range
Dim cell as range
Dim mydate as date
Dim mydiff as long
Set rng = Range ("E5: E17") Set rng2 = Range ("E5: E17") Dim cell2 As Range
Dim i As Integer i = 5
For each row In rng.Rows For each cell In row.Cells
MsgBox cell.Value mydate = cell.Value myDiff = DateDiff("d", Date, mydate) Set rng2 = Range("F" & i) For Each cell2 In rng2 MsgBox cell2.Value Next cell2
If myDiff> -8 And myDiff <Then aEmail.Send End If
i = i + 1 Next cell Next line
excel-vba excel
user2286756
source share