procedure TForm1.Button1Click(Sender: TObject);var
Present: TDateTime;
Year, Month, Day, Hour, Min, Sec, MSec: Word;
begin
Present:= Now;
DecodeDate(Present, Year, Month, Day);
Label1.Caption := 'Today is Day ' + IntToStr(Day) + ' of Month '
+ IntToStr(Month) + ' of Year ' + IntToStr(Year);
DecodeTime(Present, Hour, Min, Sec, MSec);
Label2.Caption := 'The time is Minute ' + IntToStr(Min) + ' of Hour '
+ IntToStr(Hour);
end;
Present: TDateTime;
Year, Month, Day, Hour, Min, Sec, MSec: Word;
begin
Present:= Now;
DecodeDate(Present, Year, Month, Day);
Label1.Caption := 'Today is Day ' + IntToStr(Day) + ' of Month '
+ IntToStr(Month) + ' of Year ' + IntToStr(Year);
DecodeTime(Present, Hour, Min, Sec, MSec);
Label2.Caption := 'The time is Minute ' + IntToStr(Min) + ' of Hour '
+ IntToStr(Hour);
end;
解决方案 »
- 关于image1.Canvas.TextOut(x,y,name);的问题
- 急!!各位大虾帮帮忙!!谢谢
- 只在richedit中添加最新的数据而不需要全部刷新,求代码。百分相谢+鞠躬敬礼!
- 请教:程序运行时的错误!!!!
- 急,speedbutton的图象运行中改变不了
- CCC_WH进来领分
- 救命!程序太大了怎么办?!!!!!!!!!!!
- 请问在哪儿可以找到免费的数据库备份控件(有说明文档)?
- 请教大家一个简单问题,具体请看内容,一定给分。
- 各位的DELPHI都是正版的吗?我想知道我的DELPHI老是出问题,是不是盗版的缘故?
- 一个小小小问题,很容易拿,但我不知道
- ************消息框的小问题!!!!!!!!!!****************
var h,m,s,ms:word;
present:Tdatetime;
c:integer;
begin
present:=now();
decodetime(present,h,m,s,ms);
c:=m*10;
showmessage(inttostr(c));
end;