Home > Back-end > How to use Delphi formatdatetime function? The novice consult
How to use Delphi formatdatetime function? The novice consult
Time:09-26
Part of the code: Testdate>=to_date (: ST, "YYYYMMDD") and testdateParambyname (' ST '). AsString:=formatdatetime (' yyyymmdd 'datetimepicker1. Date) Parambyname (' FT). The AsString: formatdatetime=(' yyyymmdd 'datetimepicker1. Date + 10/24)
Look at the trouble where is wrong? Don't add 10/24 like is like, plus one can be like?
CodePudding user response:
Have a look at this a few function IncDay Returns a date shifted by a specified number of days. IncHour Returns a date/time value shifted by a specified number of hours. IncMilliSecond Returns a date/time value shifted by a specified number of milliseconds. IncMinute Returns a date/time value shifted by a specified number of minutes. IncSecond Returns a date/time value shifted by a specified number of seconds. IncWeek Returns a date shifted by a specified number of weekes. IncYear Returns a date shifted by a specified number of years.
To Uses DateUtils
CodePudding user response:
TDatetime is actually a double type, should be can add 10/24, 10/24 is said don't know what you're here