Sub daybetwwen2dates()
startdate = CDate(Application.InputBox("Date", Default:=Date + 1))
enddate = CDate(Application.InputBox("Date", Default:=Date + 2))
MsgBox DateDiff("d", startdate, enddate) + 1
End Sub
startdate = CDate(Application.InputBox("Date", Default:=Date + 1))
enddate = CDate(Application.InputBox("Date", Default:=Date + 2))
MsgBox DateDiff("d", startdate, enddate) + 1
End Sub
No comments:
Post a Comment