请教各位高手,如图样的自动提示是怎样做的,谢谢

解决方案 »

  1.   

    asp.net ajax控件就有这个http://www.ajaxasp.net.cn/Demos/AutoComplete/AutoComplete.aspx
      

  2.   

    net ajax  autocomplete 控件
      

  3.   

    反正是AJAX,自己写AJAX也行它这个肯定不是用的这个控件.
      

  4.   

    出錯:
    Server Error in '/study' Application.
    --------------------------------------------------------------------------------Parser Error 
    Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. Parser Error Message: Type 'AjaxControlToolkit.AutoCompleteExtender' does not have a public property named 'CompletionListCssClass'.Source Error: 
    Line 11: <asp:ScriptManager ID="ScriptManager1" runat="server">
    Line 12: </asp:ScriptManager>
    Line 13: <ajaxToolkit:AutoCompleteExtender 
    Line 14:     runat="server" 
    Line 15:     ID="autoComplete1" 
     Source File: /study/ajax/autocomplete/test01.aspx    Line: 13 
      

  5.   

    學習代碼是:<%@ Page Language="C#" ContentType="text/html" ResponseEncoding="utf-8" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>
    </head>
    <body>
    <form runat="server">
    客戶<asp:TextBox runat="server" ID="txt1"/>
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <ajaxToolkit:AutoCompleteExtender 
        runat="server" 
        ID="autoComplete1" 
        TargetControlID="txt1"
        ServiceMethod="GetCompletionList"
        ServicePath="AutoComplete.asmx"
        MinimumPrefixLength="2" 
        CompletionInterval="1000"
        EnableCaching="true"
        CompletionSetCount="20" 
        CompletionListCssClass=
            "autocomplete_completionListElement" 
        CompletionListItemCssClass=
            "autocomplete_listItem" 
        CompletionListHighlightedItemCssClass=
            "autocomplete_highlightedListItem"
        DelimiterCharacters=";, :">
            <Animations>
                <OnShow> ... </OnShow>
                <OnHide> ... </OnHide>
            </Animations>
    </ajaxToolkit:AutoCompleteExtender>
    </form></body>
    </html>