SetFocusOnError Property of Validation Control in ASP.Net

Here, we learn how to use SetFocusOnError Property of Validation Control in ASP.Net.

All validation control has a SetFocusOnError property.

If you set SetFocusOnError=True  then when this validation control fail and show the error message then our mouse focus automatically that failed control.

If we use multiple validation controls, multiple validation controls fail then first validation control gets focus.

Here we take SetFocusOnError example with Requiredfieldvalidatior control.

how to use SetFocusOnError property in asp.net

how to use SetFocusOnError property in asp.net

The ASP.Net web form design code is :

how to use SetFocusOnError property in asp.net

how to use SetFocusOnError property in asp.net

how to use SetFocusOnError property in asp.net

how to use SetFocusOnError property in asp.net

 

Leave a Reply

Your email address will not be published. Required fields are marked *

4 + 9 =


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">