L
Liam.M
Hey guys, I need some help.
In my Database I use V.B to display a Calandar(2) to the user, who then
selects the date they want, which is then displayed back to them in a
date/time field I have created, named "DateofIssue". I want to create
another date/time field (lets call it Due Date) whereby it calculates a
"One year" period from whatever the date the user has selected from the
Calandar2 function (which then transfers this date to the "DateofIssue"
date/time field. I am having trouble implementing the "=DateAdd"
function, as many of the threads on here discuss. The V.B code I am
using to display the calandar2 function, which the user selects such
and such date, and then it exhibits the date in the "DateofIssue"
field, is as follows:
Private Sub DateofIssue_MouseDown(Button As Integer, Shift As Integer,
X As Single, Y As Single)
Calendar2.Visible = True
Calendar2.SetFocus
If Not IsNull(DateofIssue) Then
Calendar2.Value = DateofIssue.Value
Else
Calendar2.Value = Date
End If
End Sub
Am I surposed to add code to this function that automatically
calculates "one year" from the selected date, that would then show this
result in the "Due Date" field, or am I surposed to create code within
the "Due Date" field?
If someone could please help me with this, it would be greatly
appreciated, and HELP with the code would be even more appreciated!
Thanxs, and kind regards
Liam Murphy
In my Database I use V.B to display a Calandar(2) to the user, who then
selects the date they want, which is then displayed back to them in a
date/time field I have created, named "DateofIssue". I want to create
another date/time field (lets call it Due Date) whereby it calculates a
"One year" period from whatever the date the user has selected from the
Calandar2 function (which then transfers this date to the "DateofIssue"
date/time field. I am having trouble implementing the "=DateAdd"
function, as many of the threads on here discuss. The V.B code I am
using to display the calandar2 function, which the user selects such
and such date, and then it exhibits the date in the "DateofIssue"
field, is as follows:
Private Sub DateofIssue_MouseDown(Button As Integer, Shift As Integer,
X As Single, Y As Single)
Calendar2.Visible = True
Calendar2.SetFocus
If Not IsNull(DateofIssue) Then
Calendar2.Value = DateofIssue.Value
Else
Calendar2.Value = Date
End If
End Sub
Am I surposed to add code to this function that automatically
calculates "one year" from the selected date, that would then show this
result in the "Due Date" field, or am I surposed to create code within
the "Due Date" field?
If someone could please help me with this, it would be greatly
appreciated, and HELP with the code would be even more appreciated!
Thanxs, and kind regards
Liam Murphy