Year Function
DateSerial āˇāˇ DateValue āˇāˇâāļģāˇāļāļēāļāˇāļąāˇ āļĸāļąāļąāļē āļāļŊ āˇāˇâāļģāˇāļĢāˇāļāļ āļ¯āˇāļąāļēāļāˇāļąāˇ āˇāˇāļģāˇ āļ¸āˇāˇāļē āļāļ´āˇāˇ āļŊāļļāˇāļ¯āˇāļēāˇ.
āļāˇāļģāļ āļģāˇāļāˇāļē:
Tan (āļ
āļāļāļē)
āļāļ´āˇāˇ āļŊāļļāˇāļ¯āˇāļą āļ āļāļē:
Integer
āļ´āļģāˇāļ¸āˇāļāˇāļąāˇ:
Number: āļāļāˇāļ´āļģ āļāļĢāļą āļāļĢāļąāļē āļāˇāļģāˇāļ¸āļ§ āļēāˇāļ¯āˇ āļāļąāˇāļąāˇ āļ āļąāˇāļāļ¸ āļāˇāļŊ āļ āļāļāļē āļ āļŠāļāļāˇ āˇāļāļāˇâāļēāˇ āļ´āˇâāļģāļāˇāˇāļąāļē.
This function is the opposite of the DateSerial function, and returns the year of a serial date. For example, the expression:
Print Year(DateSerial(1994, 12, 20))
returns the value 12.
āļāļ¯āˇāˇāļģāļĢāļē:
Sub ExampleYear
MsgBox "" & Year(Now) ,64,"Current year"
End Sub