Solved

vam:requiredtextvalidator how to enable it on codebehind?

Posted on 2008-10-14
3
248 Views
Last Modified: 2008-10-26
vam:requiredtextvalidator how to enable it on codebehind?
i want to do it dynamicaly on the basis of a business logic. please help
0
Comment
Question by:x1877
  • 2
3 Comments
 
LVL 26

Expert Comment

by:Anurag Thakur
ID: 22752344
0
 

Author Comment

by:x1877
ID: 22770924
Thats a good site ragi0017 - Thanks
0
 

Accepted Solution

by:
x1877 earned 0 total points
ID: 22771022
This is the code i added to get this done

i set the enabled property to false on design time.

<vam:requiredtextvalidator enabled="false"


and added the following code on code behind. So it will enabled only if the businse case matches
RequiredTextValidator vldEditPrimaryDayPhoneRequired = ctlWorkflow.FindControl("vldEditPrimaryDayPhoneRequired") as RequiredTextValidator;
						vldEditPrimaryDayPhoneRequired.Enabled = true;
	vldEditPrimaryDayPhoneRequired.EnableClientScript = true;

Open in new window

0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
converto datetime always changes format 9 37
Problem!!! 8 33
Sending receiving text messages in vb.net 15 38
asp.net mvc5 6 17
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question