Hi everybody,
I have a userform with a textbox Start Date,End Date & # of days.
I looking for the code that gives me the result as shown in the table when I press the
button.
Belleke
Without Your sample file,
Your would get an idea from next to samples:
Code:
Sub Do_It()
' get Your start_date, end_date, days as needed
For d = start_date To end_date
Cells(d - start_date + 2, 2) = d
Next d
' OR
For d = 0 To days
Cells(2 + d, 2) = start_date + d
Next d
End Sub
Belleke
You didn't test my samples.. hmm?
Your file has 'something' which won't work with my Excel,
but here one sample version as You've written. Ps. You would add line On Error Resume Next in then beginning of that Sub.