E
Excel-General
Hi:
I wanted this macro to accept the date the user gives in the dialog
box. In all the sheets on the range v6 it should put that date but it
should only be on sheets2 and onward not on sheet1. I wanted it to
only ask for the date once. This macro asks for the date on every
iteration and I don't know how to set the value for the variable
inputDate? It doesn't change anything if I move the variable on the
right or left side of the function.
Thanks again.
Sub months1()
Dim inputDate As Date
Dim i As Long
inputDate = InputBox("Enter a date:", "Date", Date)
For i = 2 To Worksheets.Count
Sheets(i).Range("v6") = inputDate
Next i
End Sub
I wanted this macro to accept the date the user gives in the dialog
box. In all the sheets on the range v6 it should put that date but it
should only be on sheets2 and onward not on sheet1. I wanted it to
only ask for the date once. This macro asks for the date on every
iteration and I don't know how to set the value for the variable
inputDate? It doesn't change anything if I move the variable on the
right or left side of the function.
Thanks again.
Sub months1()
Dim inputDate As Date
Dim i As Long
inputDate = InputBox("Enter a date:", "Date", Date)
For i = 2 To Worksheets.Count
Sheets(i).Range("v6") = inputDate
Next i
End Sub