A
andreas
Hello,
below macro applies a custom paragraph style from the second row to
the last row of a selected table. Can this code be improved, e.g. by
not using the selection object when setting the range?
Help is appreciated. Thank you very much in advance.
Sub ApplyStyleSecondToLastRow()
Selection.Tables(1).Select
Selection.SetRange _
Start:=Selection.Rows(2).Range.Start, _
End:=Selection.End
Selection.Style = "custom paragraph style"
End Sub
below macro applies a custom paragraph style from the second row to
the last row of a selected table. Can this code be improved, e.g. by
not using the selection object when setting the range?
Help is appreciated. Thank you very much in advance.
Sub ApplyStyleSecondToLastRow()
Selection.Tables(1).Select
Selection.SetRange _
Start:=Selection.Rows(2).Range.Start, _
End:=Selection.End
Selection.Style = "custom paragraph style"
End Sub