I want the following code to run across multiple sheets.
How can I do this?
Right now I have a macro for each sheet and it runs successfully.
Want to be able to mail to specific people throughout the workbook that meet the criteria.
------------------------------------------
For Each cell In Columns("O").Cells.SpecialCells(xlCellTypeConstants)
If cell.Value Like "?*@?*.?*" And _
LCase(Cells(cell.Row, "V").Value) = "yes" Then
Set OutMail = OutApp.CreateItem(0)
On Error Resume Next
With OutMail
.To = cell.Value
.Subject = Sheet5.Range("A3").Value
.Body = "Dear " & Sheet5.Cells(cell.Row, "I").Value & "," _
& vbNewLine & vbNewLine & _
Cells(9, 23).Value _
.Send
End With
On Error GoTo 0
Set OutMail = Nothing
End If
Next cell
Bookmarks