/// <summary> /// Called by the ASP.NET page framework to notify server controls that use composition-based implementation to create any child controls they contain in preparation for posting back or rendering. /// </summary> protected override void CreateChildControls() { base.CreateChildControls(); dataValidator = new Validation.DataAnnotationValidator(); dataValidator.ID = this.ID + "_dav"; dataValidator.ControlToValidate = this.ID; dataValidator.Display = ValidatorDisplay.None; dataValidator.CssClass = "validation-error help-inline"; Controls.Add(dataValidator); }
/// <summary> /// Called by the ASP.NET page framework to notify server controls that use composition-based implementation to create any child controls they contain in preparation for posting back or rendering. /// </summary> protected override void CreateChildControls() { base.CreateChildControls(); Controls.Clear(); label = new Label(); label.AssociatedControlID = this.ID; validator = new Validation.DataAnnotationValidator(); validator.ID = this.ID + "_dav"; validator.ControlToValidate = this.ID; validator.Display = ValidatorDisplay.None; validator.ForeColor = System.Drawing.Color.Red; Controls.Add(label); Controls.Add(validator); }
/// <summary> /// Called by the ASP.NET page framework to notify server controls that use composition-based implementation to create any child controls they contain in preparation for posting back or rendering. /// </summary> protected override void CreateChildControls() { base.CreateChildControls(); Controls.Clear(); label = new Label(); label.AssociatedControlID = this.ID; validator = new Validation.DataAnnotationValidator(); validator.ID = this.ID + "_dav"; validator.ControlToValidate = this.ID; validator.Display = ValidatorDisplay.Dynamic; validator.CssClass = "validation-error"; Controls.Add(label); Controls.Add(validator); }
/// <summary> /// Called by the ASP.NET page framework to notify server controls that use composition-based implementation to create any child controls they contain in preparation for posting back or rendering. /// </summary> protected override void CreateChildControls() { base.CreateChildControls(); dataValidator = new Validation.DataAnnotationValidator(); dataValidator.ID = this.ID + "_dav"; dataValidator.ControlToValidate = this.ID; dataValidator.Display = ValidatorDisplay.None; dataValidator.CssClass = "validation-error help-inline"; Controls.Add( dataValidator ); }
/// <summary> /// Called by the ASP.NET page framework to notify server controls that use composition-based implementation to create any child controls they contain in preparation for posting back or rendering. /// </summary> protected override void CreateChildControls() { base.CreateChildControls(); Controls.Clear(); label = new Label(); label.AssociatedControlID = this.ID; validator = new Validation.DataAnnotationValidator(); validator.ID = this.ID + "_dav"; validator.ControlToValidate = this.ID; validator.Display = ValidatorDisplay.Dynamic; validator.CssClass = "validation-error"; Controls.Add( label ); Controls.Add( validator ); }
/// <summary> /// Called by the ASP.NET page framework to notify server controls that use composition-based implementation to create any child controls they contain in preparation for posting back or rendering. /// </summary> protected override void CreateChildControls() { base.CreateChildControls(); Controls.Clear(); label = new Label(); label.AssociatedControlID = this.ID; validator = new Validation.DataAnnotationValidator(); validator.ID = this.ID + "_dav"; validator.ControlToValidate = this.ID; validator.Display = ValidatorDisplay.None; validator.ForeColor = System.Drawing.Color.Red; Controls.Add( label ); Controls.Add( validator ); }