Time Difference

I am writing an agent that deals with time. I need to be able to tell the difference between the current time and the time the document was sent. I have to send an e-mail out for every document that is over an hour old. Is there any formula to tell the difference between the two times.

Thanks for the help in advance.

Christy M DeKing

Subject: Time Difference

Hi,

I have got a formula which found difference of two time. I hope this help.

Regards

O.Senturk

X:= field_1(Last time) - field_2(first time);

Y := @Modulo(X;3600)/60;

Z :=@Round((X/3600) - (1/2));

@Text(Z) + " Hour " + @Text(@Integer(Y)) +" Minute"

Subject: Sure, its easy. Just subtract the two times. The result is in seconds.

Formula:Td := (@Now - DeliveredDate) / 60 / 60;

@If(Td > 1; “”; @Return(“”));

Your Mail code here

Script:

dd = doc.DeliveredDate(0)

Td = (Now - dd) / 60 / 60;

If Td > 1 Then

Your Mail Code here

End If