I need help in Excel. My question is: How can I get the cell 42 of each row in this loop? As:
For Each r In Sheets("Sheet2").UsedRange.Rows
     sval = r.Cells(42)
     If sval = "" Then
         If r.Cells(6).Value <> "" And r.Cells(7).Value <> "" And r.Cells(9).Value <> "" And r.Cells(10).Value <> "" And r.Cells(11).Value <> "" And r.Cells(12).Value <> "" Then
             MsgBox "wtehi"
             r.EntireRow.Interior.ColorIndex = 0
         Else
             MsgBox "yallow"
             emptyMand = "ok"
             r.EntireRow.Interior.ColorIndex = 6
         End If
     End If
Next
 
     
     
    