ASP.NET 4.5 text mode property enhancement:With HTML5 new input types is going to be one of coolest feature and in future more and more people are going to use that feature. So in asp.net 4.5 asp.net development team given a support via TextMode property enhancements.
In earlier versions of ASP.NET we used have only three properties for TextMode property of asp.net textbox control.
- MultiLine- for multiline textbox.
- Password- for password textbox
- SignleLine –for single line textbox
- Color- for Color entries
- Date- for date entries. You can enter dates only
- DateTime – for datetime entries with respect to local time zone.
- DateTimeLocal- for datetime entries with respect to local time zone.
- Email- for email address
- Month- for month and year entry.
- Number- for entering numeric values.
- Range- for containing range between two numbers.
- Search- for search field. A search field is like regular text fields
- Tel- for telephone number.
- Url- for website url entries. It will only contain urls.
- Week- for entering weeks and year.
Examples:Let’s try some examples for new asp.net 4.5 textbox HTML5 features.
Date:Here how its look when we set TextMode property as date.
Color:Here is the how it looks when we set TextMode property as color.
Month:Here’s it looks when we set TextMode property as month.
That’s it hope you like it. Stay tuned for more..