The original code works except it does not look in G for "D" nor does it include "L" in F.
If G8 = “E” and if F8 = “H” and E8 is >=10 Copy A8:G8 and paste to sheet tab Sheet40.
If G8 = “E” and if F8 = “E” and E8 is >=1 Copy A8:G8 and paste to sheet tab Sheet40.
If G8 = “E” and if F8 = “L” and E8 is >=20 Copy A8:G8 and paste to sheet tab Sheet40.
When at anytime “D” is in G8, do nothing.
If Left(Worksheets(x).Range("F8").Cells(y, 1), 1) = "E" Or _
Left(Worksheets(x).Range("F8").Cells(y, 1), 1) = "H" And _
Worksheets(x).Range("E8").Cells(y, 1) >= 9 Then
Worksheets(x).Range(Worksheets(x).Range("B8").Cells(y, 1), Worksheets(x).Range("F8").Cells(y, 1)).Copy
Worksheets("E&H").Range("a100").End(xlUp).Offset(1, 0).PasteSpecial (xlPasteAll)
Worksheets("E&H").Range("a100").End(xlUp).Offset(0, 5) = dDate
Worksheets("E&H").Range("a100").End(xlUp).Offset(0, 6) = stTab
I don't know what to do... Maybe write 2 codes and use Application.Run - the other macro name or something
Bookmarks