Programming - cpueblo.com

시/분/초 구하기. (VCL 다음 인터벌 구하기~ 냥냥)


글쓴이 : 유광희 날짜 : 2002-05-31 (금) 15:24 조회 : 13113
TDateTime Time;
int Hour, Min, Sec;
int Interval = tmrLottery->Interval / 1000;
Hour = Interval  / (60 * 60);
Min = (Interval - (Hour * 60 * 60)) / 60;
Sec = Interval - ((Hour * 60 * 60) + (Min * 60));
Time = LotteryStartTime + EncodeTime(Hour, Min, Sec, 0);

StatusBar->Panels->Items[5]->Text = FormatDateTime("yyyy:mm:dd hh:nn:ss", Time);