How to remove time from date Salesforce?

format() will remove the time stamp from Date.

Sample Code:

Date dat = System.Today();
System.debug(dat.format());

Cheers!!!

1 comment: