本文整理自网络,侵删。

uses DateUtils;
procedure TForm1.MonthCalendar1Click(Sender: TObject);begincaption:= YearOf(MonthCalendar1.Date).ToString + '-' + MonthOfTheYear(MonthCalendar1.Date).ToString + '-' + DayOfTheMonth(MonthCalendar1.Date).ToString;//caption:=DateTimeToStr(MonthCalendar1.Date);end;
相关阅读 >>
Delphi读取radiogroup选中按钮的string文本
Delphi tms web core 通过url 传递参数
Delphi debug模式下可以但是release模式下报错原因之一
Delphi tfilestream和tmemorystream分别读取、创建、合并文件
更多相关阅读请进入《Delphi》频道 >>