View Full Version : Field Type?


Ringers
09-11-2003, 04:48 PM
I am creating a text field to record the amount of time spent on the phone to customers. But all the time formats that access lets you choose change the number into a clock format.

e.g if i enter 00:10 for 10 mins call duration, acess changes it to 12:10am. I have also tried using a long interger, but this format does not have a seperator ':' so a user could tell that '10' means 10 minutes and not 10hrs.

A solution for this would be pretty simple i reckon, but i can't think of it. So any help with this would be great. ;)

WayneRyan
09-11-2003, 04:54 PM
Ringers,

Use the Long integer. It is the amount of time in minutes. If
you need to display it differently on a form or report, you can
use the TimeSerial to display hours:minutes.

Wayne

Ringers
09-11-2003, 05:08 PM
what do you mean by time serial?

WayneRyan
09-11-2003, 06:30 PM
Ringers,

It is a function that returns a date/time when you feed it
pieces (like 272 minutes = 4:32). See Help for examples.

Wayne

Ringers
09-11-2003, 08:05 PM
I found the help file. I need '0:00' to appear and if i enter 5mins, you should see '0:05'. But at the moment all you see is '5'. That could be any value so i need that format. How do i get it?

WayneRyan
09-11-2003, 08:27 PM
Ringers,

Something like:

CStr(Int(txtMinutes/60)) & ":" & CStr(txtMinutes - Int(txtMinutes/60) *60)

Wayne