RequiredFieldValidator and Custom Controls

W

William Mansfield

I am authoring the ubiquitous "Date Picker" control and have come across the need to use the required field validator. My control contains a textbox control, and other calendar pop up controls (pointless to explain), but for simplicity purposes, let us assume only the textbox needs validation. It seems to me that there must be a way to use the already defined "RequiredFieldValidator" on my control, instead of building my own custom one. Everywhere I've gone to research this all point me to creating my own validator class. So the question is: Is there a secret interface I can implement, or expose some child control to allow my control to act just like a standard control in regards to validation?
 
W

William Mansfield

Found the answer in "Developing Microsoft ASP.NET Server Controls and Components. (ValidationPropertyAttribute

It's amazing how easy things are when you pick up a book!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,265
Latest member
TodLarocca

Latest Threads

Top