Can one validation control work for multiple textboxes?

R

Russ

I have a huge form with 91 controls on it and about 1/3 of them are date
fields. Is it possible to use just one compare validator to make sure dates
are being entered or do I have to make one for each text box?

Also can someone think of a easy way to make it so all of these date text
boxes will convert a date entered like this 120203 to 12/02/2003?
 
R

Russ

I tried:

txtbox.Text = txtbox.Text.ToString("##/##/##");

It would not compile saying that their were invalid arguments.
 
J

Joe

Have you considered using dropdown lists instead of textboxes? This gives
you control of the formatting.

Joe
 

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,767
Messages
2,569,572
Members
45,045
Latest member
DRCM

Latest Threads

Top