I am aware that a date datatype field in a table can have the default value of 0 removed so that the field effectively is null until changed. This is usefull for displaying table contents on a form.
I want to manipulate dates programatically but when I Dim a variable AS Date, the variable (which I know is really a long integer) contains 0 and as a date is 12:00:00 of some long forgotten (even by me) date in the past!
I need to do something like this
[CODE=vb]If Not IsNull(Me.Exit_ Date) Then
Orig_Exit_Date = Me.Exit_Date
End If
[/CODE]
Now I can check to see if the date on the form (Me.Exit_Date) is null and if so, ignore it, but the variable (Orig_Exit_Date ) is already 0 so if I don't assign it a real date because the one on the form is null, I get ancient history.
How do I trick the variable (Orig_Exit_Date ) into thinking it is empty?
Thanks
Jim
I want to manipulate dates programatically but when I Dim a variable AS Date, the variable (which I know is really a long integer) contains 0 and as a date is 12:00:00 of some long forgotten (even by me) date in the past!
I need to do something like this
[CODE=vb]If Not IsNull(Me.Exit_ Date) Then
Orig_Exit_Date = Me.Exit_Date
End If
[/CODE]
Now I can check to see if the date on the form (Me.Exit_Date) is null and if so, ignore it, but the variable (Orig_Exit_Date ) is already 0 so if I don't assign it a real date because the one on the form is null, I get ancient history.
How do I trick the variable (Orig_Exit_Date ) into thinking it is empty?
Thanks
Jim
Comment