Client-side validation for ensuring date/time field is not later than form submission timeIssue How to check a date/time field is not later than the submission time of the form on the Client-side?Note: Different types of date/time formats are used by different users(eg: dd/mm/yyyy or mm/dd/yyyy or yyyy/mm/dd).ResolutionTo ensure that the date entered in a form is valid upon submission, utilize the onSubmit client script and include a script similar to the following. Using g_user_date_time_format function onSubmit() {var now = new Date();var dt1 = getDateFromFormat(g_form.getValue("start_date_time"), g_user_date_time_format);if (dt1 > now) {g_form.addErrorMessage("Start Date must be before current time.");return false;}} Using g_user_date_format function onSubmit() {var currentDateObj = new Date();var currentDateStr = formatDate(currentDateObj, g_user_date_format);var currentDateNum = getDateFromFormat(currentDateStr, g_user_date_format);var startDateNum = getDateFromFormat(newValue, g_user_date_format);if (startDateNum > currentDateNum) {g_form.showFieldMsg('Start Date must be before current time.', 'error');return false;}}Related LinksThe Secrets of GlideDateTime