在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
var AMonthFirst, AMonthLast: TDateTime); var Year, Month, Day: Word; begin DecodeDate(ADate, Year, Month, Day); AMonthFirst := EncodeDate(Year, Month, 1); if Month + 1 > 12 then AMonthLast := EncodeDate(Year + 1, 1, 1) - 1 else AMonthLast := EncodeDate(Year, Month + 1, 1) - 1 end; procedure GetMonthDay(const ADate: TDateTime; var AMonthFirst, AMonthLast: TDateTime); var Year, Month, Day: Word; begin DecodeDate(ADate, Year, Month, Day); AMonthFirst := EncodeDate(Year, Month, 1); AMonthLast := EncodeDate(Year, Inc(Month), 1) - 1 end; 每月第一天:Encodedate(year,month,1); 每月最后一天:Encodedate(year,Inc(month),1)-1; 第一天:StrToDate('2000-01-01') 最后一天:strToDate('2000-02-01')-1 |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论