Ok so I need a vba program that will select two non-adjacent rows and the row numbers need to be variables. Attached is an example of what I have so far. Range("2:2,4:4").Select won’t let me substitute variables for the 2 and 4. Rows(2).Select and Rows(4).Select I could substitute variables for the 2 and 4 but I don’t get 2 non-adjacent rows. Any help will be appreciated. Thanks in advance.
Sub Select1()
Dim N As Integer
Dim M As Integer
Range("2:2,4:4").Select
N = 2
M = 4
Rows(N).Select
Rows(M).Select
End Sub
Sub Select1()
Dim N As Integer
Dim M As Integer
Range("2:2,4:4").Select
N = 2
M = 4
Rows(N).Select
Rows(M).Select
End Sub