RangeValidator Control Example:
Introduction:
In my previous article i explained overview of ValidationControls in Asp.net,How to use requiredfieldvalidator in Asp.Net.Now i will explain How to use RangeValidator Control in Asp.Net.
Description:
You can use the ASP.NET RangeValidator control to determince whether a user's entry falls within specific range of values - for example, between two numbers, between two dates or between alphabetic characters.
You set the upper and lower bounds of the range as properties of a RangeValidator Control. You must also specify the data type of the values that the control will validate.
To Use this:
1). Add a RangeValidator control to the page and set the properties ControlToValidate,ErrorMessage,Text and Display.
2). Set the low and high values of the range using MinimumValue and Maximumvalue properties.
3). Set the type property to specify the datatype of the range settings. use the ValidationDataType enumeration, which enables you to specify the following types
- String
- Integer
- Double
- Date
- Currency
RangeValidator Example phone number and Date Validation:
Related Tutorials
- Architecture of WPF.
- Creation of Three Tier Architecture in .Net Application.
- Difference between App.config and Web.Config
- Asp.Net Validation Controls Tutorial
- Asp.Net Ajax Tutorials
- Difference between Machine.Config and Web.Config in Asp.Net Framework.
- Basic Drawings and Shapes in WPF.
- How to read and write key values from and to App.config Settings file .Net Windows Application.
- How to Use RangeValidator Control in Asp.Net with Example.
- Asp.Net Ajax Server Controls, Ajax Control Toolkit Download and Installation Tutorial.
- How to Use ViewState in Asp.Net(State Management Techniques).
- How to use Hidden Field in Asp.Net with Example(State Managemet Techniques).
- Beginners Tutorial on How to use QueryStrings in Asp.Net(State Management Techniques).
- Asp.Net Cookie Usage Overview with example(State Management Techniques).
- Access Specifiers or Modifiers in C# with example(Oops Concept).
No comments:
Post a Comment
Please Give your Valuable Suggestions,Questions and Comments to improve my blog.