I created this loop below. Now I need to add code that will divide Range ("C" & i) by the closest cell (going down, not up) with formatting that has an upper line border. How can I add this?
![]()
Sub mil() For i = 3 To 15 If Range("C" & i).Borders(xlEdgeTop).LineStyle = xlLineStyleNone Then Else Range("D" & i) = Range("C" & i) 'Divide by the closest cell with a top border End If Next End Sub
Bookmarks