Hello
I have this simple loop script to update a date-time field with a date/time specified. I have the variable being passed in as a DateTime, but im receiving and error that the timechange variable needs to be datetime? It already is?
Can you look and see why this is erroring out?
//Define the query to locate all the records that match a zip code.
query = "Zip_Code:equals:75056";
//Create the list
col_leads = zoho.crm.searchRecords("Leads", query);
//Date-Time for the record update.
timechange = '11/04/2018 12:00:00';
info timechange;
for each index val in col_leads
{
leadid = col_leads.get(val).getJSON("id");
result = zoho.crm.update("Leads",ToLong(leadid),{"Record_Refreshed":timechange});
info result;
}