Posted on 2004-08-09
Currently I am working on a project where I want the user type in a date in a text box. When the user types in that date I want another text box to display the end date of that month. So if someone types in 1/1/2004 in one text box the other text box would display 01/31/2004. So basically I will be adding 30/31 days to a starting date. I have written some code like this before in VB which is as follows:
Private Sub Text37_Change()
Dim input3 As Date
Dim output2 As Date
input3 = Val(Text37.Text)
output2 = input3 + 30
Text39.Text = FormatNumber(output2, 2)
Problem is when I use it in Access it tells me that FormatNumber procedure/function needs to be referenced. Any Idea what procedure should I refer to use this?
Or any other way I could solve the above problem?
Thank you so much in advance.