by Victor Francisco Cajarito (Philippines) (2 Submissions)
Category: Miscellaneous
Compatability: Visual Basic 5.0
Difficulty: Unknown Difficulty
Originally Published: Wed 6th October 1999
Date Added: Mon 8th February 2021
Rating:
(1 Votes)
How to control the system date and how to add a value by DAY,MONTH and YEAR.
'TEXT1 is a Current Date
'TEXT2 is a date to be added
'Syntax : DATEADD(what is the value, interval, Object)
'Value
'D =Day
'Y = Year
'm = Month
'w = week
'etc...
Private Sub text1_keypress(Keypress as integer)
TEXT2.TEXT = DATEADD("D", 1, TEXT1.TEXT)
End Sub
'The result is
' Current Date 09-14-72
' The Date Added on the TEXT2 is 09-15-72
No comments have been posted about How to control the system date and how to add a value by DAY,MONTH and YEAR.. Why not be the first to post a comment about How to control the system date and how to add a value by DAY,MONTH and YEAR..