Domino Code Fragment

Code Name*
dates comparisons
Date*
09/21/2001
Source (or email address if you prefer)*
Francois
IP address:.213.244.2.85
Description*
Just a tip to compare 2 dates in lotusScript
Type*
LotusScript
Categories*
Date/Time Handling
Implementation:
None (plug and play)
Required Client:
(none)
Server:
(none)
Limitations:
Comments:
Files/Graphics attachments (if applicable): Code:
With text it's easier to compare date...
1st : with a function

function (date1 as string,date2 as string) as integer
Dim date1var As Variant
Dim date2var As Variant
datedebvar=Cdat(date1)
date1var=Day(date1)+Month(date1)+Year(date1)
date2var=Day(date2)+Month(date2)+Year(date2)
If date2var > date1var Then
Msgbox "date2 > date1 "
Else
Msgbox "date2 < date1 "
End If
end function

2nd : with fields
Even if you have some date/time fields to handle, create text fields containing their values and use the function below.