Ejemplo n.º 1
0
        // TODO: Maybe move these to a shared utility class for use on other forms
        #region Static Utility Methods

        private static bool ValidateAndDisplayErrors([NotNull] IValidatable obj, string header = null)
        {
            var validationResult = obj.ValidateSelf();

            if (!validationResult.IsValid)
            {
                Error(validationResult.FormattedErrorMessageList(header));
            }
            return(validationResult.IsValid);
        }