min to hours

H

Hans Hesseling

Hello,

i am dutch so my englisch is not that good.

here is my question; what formule do i need to do the following;
for example
650 min / 60 min makes in access 6 hours 30, but must be 6 hours and 50 min
the formule in excel is
=GEHEEL(A25/60)+(REST(A25;60)/100)
geheel = all
can any one help me.

greetings,
Hans Hesseling
 
D

Douglas J. Steele

Your formula looks as though you're using Excel. I'd suggest asking in a
newsgroup related to Excel. There are many starting microsoft.public.excel,
or you might prefer microsoft.public.nl.office.excel

This newsgroup is for questions about Access, the database product that's
part of Office Professional.
 
H

Hans Hesseling

thanks Doug, but it is a excel formula, and i want it to be translated to
access.
 
J

James Hahn

For your calculation to make sense, the 650 figure cannot already be a time
variable. If it's a number in the form HMM then the following calculation
will give hours and minutes
[Hours] = Int([A25] / 100)
[Minutes] = ([A25] / 100 - Int([A25] / 100)) * 100
 
J

James Hahn

Please read the question. He already knows how to do it in Excel. He needs
to know how to do it in Access.
--
 
V

Van T. Dinh

Hours = TotalMins \ 60
Mins = TotalMins MOD 60

Note that the backward slash is for integer division, not the normal
arithmetic division /.

The MOD above is the Modulus function in English. You will need to find the
equivalent in Dutch.

If you want to display as hh:mm the use:

Format$(Hours, "0") & ":" & Format$(Mins, "00")

(Hours and Mins from above)

HTH
Van T. Dinh
MVP (Access)
 
Top