Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert Number Field to Time Field (Minutes) 1

Status
Not open for further replies.

dstalls

Programmer
Sep 27, 2007
18
US
I saw various entries on converting number to time (but nothing specific to minutes)...

I am using Crystal 2008. I have a number value {Location_Appointment_Type.Lead_Time_Length} that I want to subtract from a datetime value {Appointment.Start_Date}.

Specifically, it is to create a begin time for patients subtracting a lead time from the appointment start datetime.

For example, if the appt. starts on 10/15 at 8:05 (datetime field) and I have a 15 minute lead time (number field). I would like to showthat the appointment strats at 7:50.

I seem to be able to get the number value converted to seconds pretty easily, but am having difficulty coverting to minutes.

Any help is appreciated. Thanks!
 
What does the number look like and what does it count? If it already represents minutes, you can just use:

dateadd("n",{table.leadtimenumber},{table.apptdatetime})

"n" is for minutes.

-LB
 
Thanks lbass! That was it. I should have figured that one out... I appreciate your time!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top