Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Validating date field
Message
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00811507
Message ID:
00811557
Vues:
11
Cathi,

I just read the message # you referred to a few times (I probably need to try to understand instead of just reading <g>) but not clear about something.

In the message example, I believe, you use a textbox bound to a data. But what if the asp.net form has a textbox not bound to a data field? That is, all you want is that the textbox would appear as " / / " so that user enters a date?

>Dmitry,
>
>You need to use the Format and Parse methods. See message #670154 for an explanation. The example is how to format for currency. For dates you would use the ToString("d") instead.
>
>>What do you do to present a data field in a textbox?
>>I don't see a "native" way to display it as "mm/dd/yyyy".
>>
>>So do you just let the user type the date (maybe indicating with the label that the expected format is 'mm/dd/yyyy'?
>>And then validate the date entry?
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform