When the mask is set to be Regex and in code the InputValue of the control is set, the validation is not triggered and the error message is visualized.