Help and Support
 

powered byLive Search

BUG: AutoComplete Does Not Work When You Use Script to Submit a Form

Article ID:329156
Last Review:May 21, 2007
Revision:3.1
This article was previously published under Q329156
On This Page

SYMPTOMS

The AutoComplete feature does not work when you use script to submit a form. For example, AutoComplete may not function when you view Microsoft ASP.NET Web Forms that use postback to process events on controls other than the Submit button.


Back to the top

WORKAROUND

To work around this problem, explicitly save the form in the AutoComplete data store:
1.Copy the following code to create an HTML page:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<SCRIPT>
function subForm()
{
window.external.AutoCompleteSaveForm(f1);
f1.submit();
}
</script>
</HEAD>
<BODY>
<FORM id=f1>
User ID : <input type=text name=id></input><br>
Password :<input type=password name=pw></input><br>
E-mail :<input type = text VCARD_NAME = "vCard.Email"> <br>
<input type=button value=submit onclick="subForm()">
</FORM>
</BODY>
</HTML>
					
2.Fill in the correct information, and then click Submit.
3.Revisit the page, and then type in a field that has the same name as a stored field. The AutoComplete attribute works; it provides an AutoComplete box that contains a list of previously-stored data.

Back to the top

STATUS

Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.

Back to the top

MORE INFORMATION

Steps to Reproduce the Behavior

1.Copy the following code to create an HTML page:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<SCRIPT>
function subForm()
{
f1.submit();
}
</script>
</HEAD>
<BODY>
<FORM id=f1>
User ID : <input type=text name=id></input><br>
Password :<input type=password name=pw></input><br>
E-mail :<input type = text VCARD_NAME = "vCard.Email"> <br>
<input type=button value=submit onclick="subForm()">
</FORM>
</BODY>
</HTML> 
					
2.Fill in the correct information, and then click Submit.
3.Revisit the page, and then type in a field that has the same name as a stored field. The AutoComplete attribute does not work; it does not provide an AutoComplete box that contains a list of previously-stored data.

Back to the top

REFERENCES

For more information about AutoCompleteSaveForm, visit the following Microsoft Web sites:
AutoCompleteSaveForm Method (http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/methods/AutoCompleteSaveForm.asp)
Using AutoComplete in HTML Forms (http://msdn.microsoft.com/library/default.asp?url=/workshop/author/forms/autocomplete_ovr.asp)
AUTOCOMPLETE Attribute | autocomplete Property (http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/properties/autocomplete.asp)

Back to the top


APPLIES TO
Microsoft Internet Explorer (Programming) 5.5 SP2

Back to the top

Keywords: 
kbbug kbpending KB329156

Back to the top

Article Translations

 

Other Support Options

  • Need More Help?
    Contact a Support professional by E-mail, Online or Phone.
  • Customer Service
    For non-technical assistance with product purchases, subscriptions, online services, events, training courses, corporate sales, piracy issues, and more.
  • Newsgroups
    Pose a question to other users. Discussion groups and Forums about specific Microsoft products, technologies, and services.