The information in this article applies to:
SYMPTOMSThe DateValue function does not appear to use time as part of its filter criteria when filtering appointments. CAUSEIf the date argument includes time information, DateValue does not return the time. However, if the date includes invalid time information (such as "89:98"), an error occurs. RESOLUTIONIf you want to apply a filter to your AppointmentItems collection that includes time as part of either the StartTime or EndTime, do not use the DateValue function. STATUSThis behavior is by design. MORE INFORMATIONWhen filtering an AppointmentItem collection you need to use code similar to the following: NOTE: EndTime and StartTime are in vbDate format.
If you want to filter for all appointments that start after 10:00 AM on January 1, 1998, the following line will not work because DateValue does not return the time value:
The code above returns all the appointments on January 1, 1998, instead of
the appointments for 10:00 AM.
The proper way to use a time filter is to employ one of the following two examples:
REFERENCESFor more information, please see the following article in the Microsoft Knowledge Base: Q178508 HOWTO: Write a VB MessageFilter for Your Appointment CollectionMicrosoft Visual Basic Online: DateValue Additional query words:
Keywords : kbASP100 kbCDO120 kbMsg kbVBp500 kbGrpMsg |
Last Reviewed: November 9, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |