.NET programming tips and solution

In Web forms, when we start type in the text box, we will get the values we have typed in that field before. This is known as Auto Complete Feature. This feature is helpful in entering redundant values.

Sometimes we may want to turn off the feature as we should not reveal secret information such as social security number or credit card number.

How to turn off the auto complete feature.

To turn off auto complete for the entire form, all we need to do is add an attribute to our form tag, like this:

< form id="Form1" method="post" runat="server" autocomplete="off" >

.....

< /form >

How to turn off auto-complete feature in Control

We can do it at design time or at run time.

At design time:

Drag the asp text box control and place on the form and include the following