Form_CustomValidate for GridEdit and MultiEdit not work.
// Form Custom Validate event
function Form_CustomValidate(&$customError)
{
$myCount = ExecuteScalar("SELECT COUNT(*) FROM stock WHERE stock.StockSerialNumber = "."'".CurrentPage()->InboundItemSerialNumber->CurrentValue."'"."");
$Language = Container("language");
if ($myCount != 0) {
$this->InboundItemSerialNumber->addErrorMessage($Language->phrase("Duplicated"));
return false;
}
return true;
}
when the above conditions are met You'll usually see a Error message below the input field. But in the latest template No error message appears, but the gridedit or multiedit page is closed and the data is not edited.