function readOnly(count){ }
Don't have an account?
Search for an answer or ask a question of the zone or Customer Support.
You need to sign in to do that
Sign in to start searching questions
Signup for a Developer Edition
Sign in to start a discussion
Datetime nowTime = Datetime.now(); String DateStr = String.valueOf(nowTime.date()); String timeStr = String.valueOf(nowTime.time()); System.debug(DateStr + ' : ' + timeStr);
Please find the below code:
Please do let me know if it helps you.
Regards,
Mahesh
For more information:
date()
Returns the Date component of a Datetime in the local time zone of the context user.
time()
Returns the time component of a Datetime in the local time zone of the context user.
For more information:
https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_methods_system_datetime.htm%23apex_methods_system_datetime
http://salesforce.stackexchange.com/questions/5430/how-to-split-startdatetime-field-of-activity-event
Regards,
Mahesh