Geeks Talk

Prepare for your Next Interview




Validation Controls in ASP.NET

This is a discussion on Validation Controls in ASP.NET within the ASP.NET forums, part of the Web Development category; Hello all, In one of the interviews that i gave recently, I was asked about how many types of validation controls exist in ASP.NET? I gave the answer as ...


Go Back   Geeks Talk > Web Development > ASP.NET

Register FAQ Members List Calendar Mark Forums Read
  #1 (permalink)  
Old 05-30-2008
Junior Member
 
Join Date: Jan 2008
Location: mumbai
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
sameerphatak is on a distinguished road
Validation Controls in ASP.NET

Hello all,

In one of the interviews that i gave recently, I was asked about how many types of validation controls exist in ASP.NET? I gave the answer as 6

The next question asked was.. what is the advantage of using Validation Controls instead of normal coding? I gave the answer : because it reduces time. She was not very convinced with this answer. Guys do you have any other answers for this question??

Thanks in advance to all who answer.

Rgds,
Sameer
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-30-2008
Contributing Member
 
Join Date: Jun 2007
Location: Delhi, India
Posts: 46
Thanks: 0
Thanked 18 Times in 15 Posts
vikasvaidya is on a distinguished road
Re: Validation Controls in ASP.NET

Hi Sameer,

Advantages of using Validation controls

1. Validation controls automatically uses Client-side validation for IE 4.0 or later
2. Each of the validation controls is having so many properties that can be set as per your need. Better customization instead of manual coding.

There could be some more advantages, but these two are main differences.


---V V---
Vikas Vaidya

Please mark this post as Thank if u found the answer useful
Reply With Quote
The Following User Says Thank You to vikasvaidya For This Useful Post:
  #3 (permalink)  
Old 06-03-2008
Expert Member
 
Join Date: Dec 2007
Location: Pune
Posts: 128
Thanks: 0
Thanked 5 Times in 5 Posts
peeyush_jain is on a distinguished road
Re: Validation Controls in ASP.NET

Yes dear , your answer was correct but the way yoiu have anwser might be not perfect..

Validation are perform at client side so they dont require server trip hence the page operation is fast,
You can get more information regarding validation from below link.
ASP.NET Validator Controls
Reply With Quote
  #4 (permalink)  
Old 06-11-2008
Junior Member
 
Join Date: Jun 2008
Location: india
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
infoeweb is on a distinguished road
Re: Validation Controls in ASP.NET

all the validation controls ckecks both side client side and server side.if the page having any java script code this code will fire first than validation control checking. it takes little more time than javascript code .. in real time web application the validation controls doesnot provide full control or some user define code until u use custom control

vijay
Reply With Quote
  #5 (permalink)  
Old 06-16-2008
Expert Member
 
Join Date: Dec 2007
Location: Pune
Posts: 128
Thanks: 0
Thanked 5 Times in 5 Posts
peeyush_jain is on a distinguished road
Re: Validation Controls in ASP.NET

Every web application need some validation at UI bvos every time for validation request should not go to sever , so i think most of the developers choice is client side validation however in some of the cases they also use server side validation.
Reply With Quote
  #6 (permalink)  
Old 06-26-2008
Junior Member
 
Join Date: Jun 2008
Location: chennai
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
rampalani is on a distinguished road
Re: Validation Controls in ASP.NET

"Because validation controls avoids round trip" if u had used this phrase, u would have knocked her down.
Reply With Quote
  #7 (permalink)  
Old 06-28-2008
Junior Member
 
Join Date: Jun 2008
Location: INDIA LUCKNOW
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
siddiq_ak25 is on a distinguished road
Re: Validation Controls in ASP.NET

Quote:
Originally Posted by sameerphatak View Post
Hello all,

In one of the interviews that i gave recently, I was asked about how many types of validation controls exist in ASP.NET? I gave the answer as 6

The next question asked was.. what is the advantage of using Validation Controls instead of normal coding? I gave the answer : because it reduces time. She was not very convinced with this answer. Guys do you have any other answers for this question??

Thanks in advance to all who answer.

Rgds,
Sameer
it is been done so these validation check are called front end check they are put check on client side when page is loaded on client computer once all check are done then only page will be post back
Reply With Quote
  #8 (permalink)  
Old 06-28-2008
Expert Member
 
Join Date: Dec 2007
Location: Pune
Posts: 128
Thanks: 0
Thanked 5 Times in 5 Posts
peeyush_jain is on a distinguished road
Re: Validation Controls in ASP.NET

Hey friend there are lots of advantage to implement validation , please dont answer all at atime try to convence.
The first one is , we need to validate the input type , a good practise for programming is dont take wrong input type and dont send request to server again and again. take the example of any registration page that have lots of the field and if user input wrong data type or empyt value or much long data then the bad request to the will increase and we should reduce the load to server and validate all inputs to the user level only.
please le tm eknow if you need any more example
Reply With Quote
  #9 (permalink)  
Old 07-19-2008
Junior Member
 
Join Date: Dec 2007
Location: Chennai
Posts: 10
Thanks: 1
Thanked 1 Time in 1 Post
raghulvarma is on a distinguished road
Re: Validation Controls in ASP.NET

Actually all these validation controls operation takes place in the server side so it would take the server resources so eventually it would increase the network traffic so it is not wise to go for a validator control in the tool box. Always the validation part has to be done in the client side so the better option would be to go for the java script that makes the page more powefull, All the validators could be done with java script.
Reply With Quote
  #10 (permalink)  
Old 07-21-2008
Junior Member
 
Join Date: Jul 2008
Location: bangalore
Posts: 5
Thanks: 0
Thanked 1 Time in 1 Post
mohsink4u is on a distinguished road
Re: Validation Controls in ASP.NET

Quote:
Originally Posted by infoeweb View Post
all the validation controls ckecks both side client side and server side.if the page having any java script code this code will fire first than validation control checking. it takes little more time than javascript code .. in real time web application the validation controls doesnot provide full control or some user define code until u use custom control

vijay
Yes Vijay i do go with you only, Both Client and server side validation comes into picture. If the application fails in client side validation, then the application goes for the server side validation, where as in case of simple it is very difficult!
Reply With Quote
  #11 (permalink)  
Old 4 Weeks Ago
Junior Member
 
Join Date: Mar 2007
Location: India
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
rakesh_mwisp is on a distinguished road
Re: Validation Controls in ASP.NET

Validation Controls validate at both Client and Server Side.....
Reply With Quote
  #12 (permalink)  
Old 4 Weeks Ago
Junior Member
 
Join Date: Jul 2008
Location: India
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
prsoorya is on a distinguished road
Re: Validation Controls in ASP.NET

There are five types of ASP.NET Validation Controls in ASP.NET Framework that includes:

1. RequiredField Validation control: prompts message if any input field is left blank. This validation control can also be used to prompt message to the user if he or she has left any input field with its default value.

2. Range Validation control: Prompts message to the user, if the data entered in the input field is not within the range of the values specified by the Maximum and Minimum properties of the validation control.

3. Comparison Validation control: Allows the user to compare two values and check for comparisons such as equality, greater-than, less-than etc.

4. RegularExpression Validation control: Allows you to validate if the format of a certain input field is correct or not.

5.Custom Validation control: Allows you to define your own condition for validating the data in the input fields. Two validation functions can be performed using Custom Validation control: first on the server-side and second on the client-side. .
Reply With Quote
  #13 (permalink)  
Old 2 Weeks Ago
Junior Member
 
Join Date: Aug 2008
Location: India
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Ketanparekh is on a distinguished road
Re: Validation Controls in ASP.NET

I m not sure but also for nt using external jscript or we write normal codes its check at server side

Quote:
Originally Posted by sameerphatak View Post
Hello all,

In one of the interviews that i gave recently, I was asked about how many types of validation controls exist in ASP.NET? I gave the answer as 6

The next question asked was.. what is the advantage of using Validation Controls instead of normal coding? I gave the answer : because it reduces time. She was not very convinced with this answer. Guys do you have any other answers for this question??

Thanks in advance to all who answer.

Rgds,
Sameer
Reply With Quote
  #14 (permalink)  
Old 2 Weeks Ago
Junior Member
 
Join Date: Aug 2008
Posts: 2
Thanks: 0
Thanked 1 Time in 1 Post
ps36452 is on a distinguished road
Re: Validation Controls in ASP.NET

I think all answers are correct but there is one thing missing.
Using client side validation only is a major security threat. someione might just submit the junk data to server if server side validation is not done. Thats why Validation controls are used which provides both client and server side validation to make it more secure.
Reply With Quote
Reply

  Geeks Talk > Web Development > ASP.NET


Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
Can QTP work with Flash controls?? saroj_parida QTP 3 05-14-2008 11:37 PM
Can Silk test help automating flash controls?? saroj_parida SilkTest 5 05-04-2008 10:56 AM
ASP.NET Controls In Java Script prabhu_manager ASP.NET 1 04-18-2008 03:12 AM
ActiveX Controls and QTP Joseph07 QTP 1 04-11-2008 09:57 PM
QTP and User Access Controls (UAC) woodyrollins QTP 1 02-07-2008 07:12 PM


All times are GMT -4. The time now is 01:07 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Copyright © 2008 GeekInterview.com. All Rights Reserved