# Converting an Integer to a Time

I have a time in minutes as an Integer and want to covert it into a time that will display to a grid hours and minutes.
Example:

Input :      Time in minutes = 745
Output: Time in hours and minutes = 12:25

I also want to compare this time with the current time now and if the time now is greater that the time listed then I want to set a Boolean flag as true.

Richard
###### Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Commented:
'Q1:
Dim t As Integer
t = 745

Dim dblD As Double
dblD = t
dblD = t / 60 / 24

Dim datD As Date
datD = dblD
MsgBox Format(datD, "hh:nn")

'Q2:

Dim datB As Date
datB = Now
datB = datB - Int(datB)

If datB > datD Then
'It's after 12:25
End If

0

Experts Exchange Solution brought to you by