Using Input masks

JMFW

Board Regular
Joined
May 26, 2004
Messages
64
Hi

I'm creating a database in which I need 2 fields containing info about the time (recorded as hours and minutes) taken to complete work. One field for the overall time and the second to record the time taken for discussion etc. These two fields will be used on a form to then calculate a percentage.

My problem is that most jobs take more than 24 hours - any mask I've tried will not accept more than 24. Can anyone help please.
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"

pritcham

Board Regular
Joined
Oct 26, 2005
Messages
128
Hi

I think that you may have to store the data a little differently (i.e. as something like a Single or Double number rather than a date/time) as I don't think Access will allow you to store > 24 hours within a date/time field (if you think about it then it makes sense - Access isn't really storing just a time and nothing else - regardless of how you may see it externally, internally I think it's using 1/1/1901 or something like that for the "date" part of a field where you're trying to just store time info.

Also, it is trying to store the time of day rather than time as a unit of length so that makes something like 29.5 hours incorrect and therefore unallowable.

If you just store it as a number (not int as you'll loose any fractional parts you need to record) then you'll be able to mask it however you want.

Hope that makes sense
Martin
 

JMFW

Board Regular
Joined
May 26, 2004
Messages
64
Hi Pritcham

Thanks for your help. I done what you suggested and it will give me the information required.

Thanks again.
Jenna :)
 

Forum statistics

Threads
1,136,301
Messages
5,674,963
Members
419,536
Latest member
Mohammed Jaffer

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top