Friday 25 October 2013

Excel Macro to get the year from given date


Sub getYear()
'To get the year of given date, you can use below function in excel macro.

MsgBox Year(Now)
'Above code will print current year

MsgBox Year("09-jan-1986")
'Above code will print 1986

End Sub




What do you think on above excel macro topic? Please provide your input, comments, questions on excel macro. I will try to reply as soon as possible. I value your opinion on Excel Macros.

No comments:

Post a Comment

Popular Posts

Search This Blog