Home » Programming / Coding

How to Turn Off / Disable AutoComplete – ASP .Net

9 July 2010 1,161 views No Comment

Many browsers support autocomplete feature, making our life easier. With this feature, browser remembers the input values we make on certain fields e.g. text field and when we go visit the webpage later on, browser make suggestions with those past values we have entered.

Sometimes this is not a desirable feature. Lets say you are on a shared computer and using your credit card to make a purchase. You sure don’t want the computer remember your credit card info.

So how you can turn off or disable autocomplete on a entire web page in asp .net?
Very simple.

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

So how you can turn off or disable autocomplete on a textbox in asp .net?

Code:
<asp:TextBox Runat="server" ID="Textbox1" autocomplete="off"></asp:TextBox>

Note that intellisense might not detect autocomplete listed. However it would work just fine if you put that on.

From our Webmaster Forum http://www.webcosmoforums.com/asp/20628-how-turn-off-disable-autocomplete-asp-net.html

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

Leave your response!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

Be nice. Keep it clean. Stay on topic. No spam.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.