Hi all! I am fairly new to the VBA portion of excel and could use some help with writing a macro!
Any help is greatly appreciated.
I am trying to write a macro that will:
Here is what I have so far which I know is no where near close, but like I said, I am very new to this, thus very confused
Sub macro1()
Dim TheDate As Variant
Dim Day As Integer
Dim Month As Integer
Dim Year As Integer
TheDate = InputBox("Insert: Date (mm/dd/yyyy)")
MsgBox (Month)
MsgBox (Day)
MsgBox (Year)
EndSub
Any help is greatly appreciated.
I am trying to write a macro that will:
- prompt the user for a date (any date) in mm/dd/yyyy format
- display the year, month, and day in separate MsgBox(es)
- display a notification as to whether or not the date entered is a past, present, or future date and if it is a past/present date then compute the difference (given in years, months, days) between the entered date and the current date
Here is what I have so far which I know is no where near close, but like I said, I am very new to this, thus very confused
Sub macro1()
Dim TheDate As Variant
Dim Day As Integer
Dim Month As Integer
Dim Year As Integer
TheDate = InputBox("Insert: Date (mm/dd/yyyy)")
MsgBox (Month)
MsgBox (Day)
MsgBox (Year)
EndSub