Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/82.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# 在GridView中使用JQuery自动完成_C#_Jquery_Autocomplete - Fatal编程技术网

C# 在GridView中使用JQuery自动完成

C# 在GridView中使用JQuery自动完成,c#,jquery,autocomplete,C#,Jquery,Autocomplete,在GridView中使用JQuery自动完成。我想在gridview中自动完成批量更新所需的功能您可以使用以下方法: jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list) <asp:TextBox id="myTextBox" /> <input type="textbox" id="ctl00_otherName_myTextBox" /> 将jquery自动完成附加到网格中id为

在GridView中使用JQuery自动完成。我想在gridview中自动完成批量更新所需的功能

您可以使用以下方法:

jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list)
<asp:TextBox id="myTextBox" />
<input type="textbox" id="ctl00_otherName_myTextBox" />
将jquery自动完成附加到网格中id为textBoxId的所有文本框(输入html控件)

elem[@id$=someID]表示所有名为“elem”的标记,其id以“someID”结尾

这是必需的,因为asp.net将更改标记的客户端id,因此如果您使用以下内容:

jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list)
<asp:TextBox id="myTextBox" />
<input type="textbox" id="ctl00_otherName_myTextBox" />

该页面将包含以下内容:

jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list)
<asp:TextBox id="myTextBox" />
<input type="textbox" id="ctl00_otherName_myTextBox" />


您需要知道,使用网格视图进行批量更新有一些严重的限制;如果在网格输入中添加两个验证,则页面大小很可能太大。

您可以使用以下方法:

jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list)
<asp:TextBox id="myTextBox" />
<input type="textbox" id="ctl00_otherName_myTextBox" />
将jquery自动完成附加到网格中id为textBoxId的所有文本框(输入html控件)

elem[@id$=someID]表示所有名为“elem”的标记,其id以“someID”结尾

这是必需的,因为asp.net将更改标记的客户端id,因此如果您使用以下内容:

jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list)
<asp:TextBox id="myTextBox" />
<input type="textbox" id="ctl00_otherName_myTextBox" />

该页面将包含以下内容:

jQuery("*[@id$=theGridId] input[@id$=textBoxId]").autocomplete(list)
<asp:TextBox id="myTextBox" />
<input type="textbox" id="ctl00_otherName_myTextBox" />


您需要知道,使用网格视图进行批量更新有一些严重的限制;如果在网格输入中添加两个验证,页面大小很可能太大…

谢谢,这帮助我在datagrid中添加了autocomplete。谢谢,这帮助我在datagrid中添加了autocomplete。