Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Previous Date

Status
Not open for further replies.

GCTIberica

Programmer
Jun 20, 2003
30
ES
Hi
Does anyone know of an easy way to find the date of the previous day?

Thanks

 
hi

Have you tried? (1 = a day)

var PreviousDate, CurrentDate : TDateTime;

PreviousDate := CurrentDate - 1


If you want to get the previous business day, you need to check for Saturday and Sundays.

lou

 
Thanks very much

I was using TDate instead of TDateTime and thats why I couldnt get it working

thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top