Nomis_Eswod
Board Regular
- Joined
- Jul 27, 2005
- Messages
- 153
Hi,
i'm trying to use the below code to automatically add a date to 1 textbox and the value 1 to another. Then using the third I want to add the 2 values, so that the third textbox shows the date from the first text plus 1 day.
For example, TextBox3 shows todays date, TextBox 9 shows one, so I want TextBox 11 to show tomorrows date.
However, it is currently adding a 1 onto the end of the date. Any ideas how to get around this?
Many thanks!
i'm trying to use the below code to automatically add a date to 1 textbox and the value 1 to another. Then using the third I want to add the 2 values, so that the third textbox shows the date from the first text plus 1 day.
For example, TextBox3 shows todays date, TextBox 9 shows one, so I want TextBox 11 to show tomorrows date.
However, it is currently adding a 1 onto the end of the date. Any ideas how to get around this?
Code:
Private Sub TextBox11_Enter()
TextBox11.Value = TextBox3.Value + TextBox9.Value
End Sub
Private Sub TextBox3_Enter()
TextBox3.Value = Format(Date, "d-mmmm-yy")
End Sub
Private Sub TextBox9_Enter()
TextBox9.Value = 1
End Sub
Many thanks!