This is a migrated thread and some comments may be shown as answers.

how to use SkinManager with ASP validation controls?

1 Answer 69 Views
SkinManager
This is a migrated thread and some comments may be shown as answers.
Rob Ainscough
Top achievements
Rank 1
Rob Ainscough asked on 03 Oct 2018, 09:24 PM

Since there doesn't appear to be a Telerik RequiredFieldValidator (or something similar) and we have to use the asp:RequiredFieldValidator ... how can we "Skin" the resulting Text output when validation is trigger?  Without being able to Skin validators thru the SkinManager it sorta makes the asp:RequiredFieldValidator useless.

Any suggestions?  Alternative approaches?

ON A SIDE NOTE: The sample code to display the validator error text inside the RadTextBox control doesn't appear to work: https://docs.telerik.com/devtools/aspnet-ajax/controls/textbox/features/validation

 

Cheers, Rob.

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 04 Oct 2018, 09:27 AM
Hello Rob,

RadFormDecorator adds colors that match its backgrounds to validation messages. You can see it in action in the following demo: https://demos.telerik.com/aspnet-ajax/formdecorator/examples/validationcontrols/defaultcs.aspx?skin=Black.

Here's also a very basic example:

<telerik:RadSkinManager runat="server" ID="rsmngr1" ShowChooser="true" RenderMode="Lightweight" Skin="Black"></telerik:RadSkinManager>
<telerik:RadFormDecorator runat="server" ID="rfd1" DecoratedControls="All" RenderMode="Lightweight" />
<asp:TextBox runat="server" ID="tb1" />
<asp:RequiredFieldValidator ErrorMessage="ERROR, fill in the field" ControlToValidate="tb1" runat="server" />
<asp:Button Text="trigger validation" ID="btn1" runat="server" />

I'll also take a look at that article in the other thread you posted, to keep each one concise.


Regards,
Marin Bratanov
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
SkinManager
Asked by
Rob Ainscough
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or