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

RadTextbox

3 Answers 208 Views
Input
This is a migrated thread and some comments may be shown as answers.
xyz
Top achievements
Rank 1
xyz asked on 05 Jan 2009, 05:34 PM
HI
I have declared RadTextbox dynamically. Can anyone please help me how to put required field validations and text validation for the textbox?
Thank you

3 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 05 Jan 2009, 06:21 PM
Hello,

I created a simple demo illustrating how to achieve the required functionality. Please find it attached to this post.

Additionally I suggest you examine the following demo:
Validation

Let us know if you need more information.

Best regards,
Daniel
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
xyz
Top achievements
Rank 1
answered on 05 Jan 2009, 06:31 PM

 

Thank you for your response.
I am using many usercontrols which are loaded dynamically. in one of the user control i hv Radscriptmanager. In this particular user control(where i hv textbox) I dont hv radscript manager because if i have more than one script manager then it says only one should be avaliable.
Source code:
<
telerik:RadTextBox ID="txtTitle" runat="server" SelectionOnFocus="SelectAll">

 

 

</telerik:RadTextBox>

 

 

<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server"

 

 

ErrorMessage="*" ControlToValidate="txtTitle"></asp:RequiredFieldValidator>

The error dialog box that I get is
scriptloadfailedexception. the script '/scriptresource.axd?......could not be loaded
Thank you

 

0
Daniel
Telerik team
answered on 08 Jan 2009, 05:46 PM
Hello,

Please make sure that your ScriptManager control is loaded before the controls which are using it.

If you want to add a ScriptManager dynamically you should check whether it is not already available. You can check this condition using ScriptManager.GetCurrent(Page) method.

Regards,
Daniel
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Input
Asked by
xyz
Top achievements
Rank 1
Answers by
Daniel
Telerik team
xyz
Top achievements
Rank 1
Share this question
or