Get Hour

Hi Expers,
First of all i`m a leecher so i only got 100 points left so bare with me xD.
Second i need a code that will show me the current hour, not the time (Timetostr(time)) but only the hour.
Thanks,
Cypher
LVL 1
cypherbadAsked:
Who is Participating?
 
SteveBayConnect With a Mentor Commented:
you could alos use the
HourOf(Now)  
from  DateUtils
0
 
SteveBayCommented:
Something like this:

var HH,MM,SS,MS : Word
begin
     DecodeTime(Now,HH,MM,SS,MS);
     ShowMessageFmt('It is Hour %d',[HH]);
end;
0
 
cypherbadAuthor Commented:
you could alos use the
HourOf(Now)  
from  DateUtils

and how to make it in a showmessage
0
 
cypherbadAuthor Commented:
i found out, thanks.
0
 
cypherbadAuthor Commented:
Thanks it worked using inttostr
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.