Sub ListMaker()
Dim n1 As Integer, n2 As Integer
Dim v As String
For Each r In Selection
s = Split(r.Value, "-")
n2 = s(1)
n1 = Right(s(0), Len(s(0)) - 1) + 1
v = s(0)
For i = n1 To n2
v = v & "," & i
Next
r.Value = v
Next
End Sub
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.