-
Crystal Report ?
I am using Crystal Report 8.5. I am trying to do a computation on a database field. The field is defined as a text field in the form of time; 00:00:34 (34 seconds). What I am trying to do is create a formula that sums the values in this field and I'm not sure how to do this or if it's even possible. The only function I saw that made any sense was the "DateAdd" but I don't believe that will work.
Hope I've explained myself well enough.
Thanks,
-Blake
-
Re: Crystal Report ?
You could use CDate() on the string to convert it to Date type data before you use it in any computation.
-
Re: Crystal Report ?
Al,
I've actually tried that...in fact, here's what the formula looked like:
Sum(CDate(mElapsedTime))
It didn't work because it was looking for a number. The format of mElapsedTime is 00:00:34 and it's stored as a Text field in an Access DB.
-
Re: Crystal Report ?
Use the CDateTime function. Then convert that into a number.
DateDiff("s",CDateTime("00:00:00"), CDateTime({mElapsedTime}))
-
Re: Crystal Report ?
-
Re: Crystal Report ?
Thanks Bruce...I'll give it a try!