My mind is fried! NOTESDATETIME

Hi,

I am an Administrator and very much a part-time developerand; as I have said my mind is fried!

The problem I have is with the concatenation of a date and time in LotusScript.

I am trying to analyse a mail-in database so that someone can view the time it took to repond to a mail.

I can calculate the time difference if there are no anomalies, but if a mail arrives outwith “core hours” (Monday – Friday 08:00 – 18:00) then I must adjust the clock to start at 08:00 the following day, or 08:00 on Monday morning if the day = 1 or 7. I can set these using the TimeOnly and Dateonly methods, but I cannot find a way to concatenate the date and time in the same Notesdatetime object.

The next issue I will then have is Bank Holidays (but the way the economic crisis is biting, there will be no banks so no bank holidays!)

Any help with the NotesDateTime issue would be appreciated, (the Global Economic issue is a Bonus question for the really gifted).

Regards

Tom

Subject: My mind is fried! NOTESDATETIME

hi tom,try this:

dateOnly = dt.DateOnly

timeOnly = dt.TimeOnly

Dim new_dt As New NotesDateTime(dateOnly + " " + timeOnly)

hopefully will help.

Subject: RE: My mind is fried! NOTESDATETIME

Thanks petr that’s exactly what I needed.

Sorry about the delay in the thanks, but I have been off for a couple of weeks.

Subject: My mind is fried! NOTESDATETIME

The main thing is what is the starting date time, if the mail arrives outside yr ‘core hours’

Then yr start date time is the following Mon 8:00 AM set the Start NotesDate time to it and use for computation

Create a New StartDateTim as NotesDateTime Object set the values as needed and work from there.

Subject: RE: My mind is fried! NOTESDATETIME

Thanks yazdi, for your help.

Sorry about the delay in the thanks, but I have been off for a couple of weeks.