Te anexo la macro
Sub LineaInclinada()
'Por.Dante Amor
'Borrando líneas anteriores
For Each s In ActiveSheet.Shapes
If s.Name = "linea1" Or s.Name = "linea2" Then
s.Delete
End If
Next
'
f = 5
Do While Cells(f, "B") <> ""
f = f + 1
Loop
f = f + 1
If f > 25 Then Exit Sub
'
Set r1 = Range("B" & f & ":B" & f)
Set r2 = Range("G" & f & ":G" & f)
Set r3 = Range("H25")
Set linea = ActiveSheet.Shapes.AddLine(r1.Left, r1.Top, r2.Left, r2.Top)
linea.Name = "linea1"
linea.Line.ForeColor.RGB = RGB(255, 0, 0)
linea.Line.Weight = 2
Set linea = ActiveSheet.Shapes.AddLine(r2.Left, r2.Top, r3.Left, r3.Top)
linea.Name = "linea2"
linea.Line.ForeColor.RGB = RGB(255, 0, 0)
linea.Line.Weight = 2
End Sub
Si quieres que la línea quede en medio de la fila, entonces ajusta el Top, como en el ejemplo:
Sub LineaInclinada()
'Por.Dante Amor
'Borrando líneas anteriores
For Each s In ActiveSheet.Shapes
If s.Name = "linea1" Or s.Name = "linea2" Then
s.Delete
End If
Next
'
f = 5
Do While Cells(f, "B") <> ""
f = f + 1
Loop
f = f + 1
If f > 25 Then Exit Sub
'
Set r1 = Range("B" & f & ":B" & f)
Set r2 = Range("G" & f & ":G" & f)
Set r3 = Range("H25")
Set linea = ActiveSheet.Shapes.AddLine(r1.Left, r1.Top - 7, r2.Left, r2.Top - 7)
linea.Name = "linea1"
linea.Line.ForeColor.RGB = RGB(255, 0, 0)
linea.Line.Weight = 2
Set linea = ActiveSheet.Shapes.AddLine(r2.Left, r2.Top - 7, r3.Left, r3.Top)
linea.Name = "linea2"
linea.Line.ForeColor.RGB = RGB(255, 0, 0)
linea.Line.Weight = 2
End Sub
sal u dos