I might be able to help more if I knew how you were taking the date value from managenow and creating your NotesDateTime object. Also, I am trying to understand why you would want to do a search on a time…I suppose that if I wanted to find tickets created at a specific time of the day, I would create a second NotesDateTime object and make it equal to today’s date plus the time you are looking for, so for example, if you were looking for all tickets created at 2pm you would do something like this:
Dim dt as New NotesDateTime(“Today 2:00PM”)<–sets NotesDateTime object equal to today at 2pm
Then use your current NotesDateTime object to figure out the time difference. So if we have another DateTime object for created date + time called cdt, we’d do something like this:
dim timeDif as Long
timeDif = dt.TimeDifference(cdt)
Then to figure out if you have found a match, mod timeDif by 84600 (which is the amount of seconds in a day) to find out if your remainder is 0. If it is, then you have found a match, because the number of seconds would have to be divisible by 84600 to work.
Something like this:
If timeDif mod 84600 = 0 then
…you have a match
End If
If you are trying to find a specific date and time, you would need to know the amount of days between today and the created date, and then multiply 86400 by that number to find the exact date.
Then again, i could have completely misread what you are trying to accomplish. Maybe more detail will give me a better idea of your goals.
2 years ago I tried to accomplish similar time search, but ended up with converting date+time to a number and comparing numbers instead. Not sure if there is a way to make it work “natively” with time fields by using > and < search operations, = worked fine.