在vb.net中动态过滤转发器列表 [英] Filter Repeater list dynamically in vb.net

查看:96
本文介绍了在vb.net中动态过滤转发器列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用带有3列(名称,描述,日期)的转发器控制列表。我需要根据在文本框中输入的关键字过滤列表,以便动态描述而无需回发。

当用户在文本框中输入单词并按回车键或制表键时,我能够过滤列表,但是对于这个解决方案,会发生回发。

当用户在文本框中输入任何字符时,有没有一种方法不会发生poatback并动态更新列表?

解决方案

mayur narsale:

当用户在文本框中输入单词并按回车键或制表键时,我可以过滤列表,但是对于这个解决方案,回发发生了。

是否有一种回发不会发生的方式用户不断输入任何字符时,列表会动态更新在文本框中?





第一点令人困惑。你根本不想要回发,或者你想要AsyncPostBack。您可以使用UpdatePanel。



对于第二点,您需要为<设置 AutoPostBack 'true' code> TextBox 并处理 TextChanged 事件。

https://msdn.microsoft.com/en-us/library/2589b44c(v=vs.85).aspx [ ^


I am using repeater control list with 3 columns(Name, Description, Date). I need to filter the list based on a keyword entered in a textbox for description dynamically without postback.
I am able to filter the list when user enter a word in textbox and presses enter key or tab key, but for this solution postback happens.
Is there a way that poatback does not happen and the list gets updated dynamically when user keeps typing any character in textbox?

解决方案

mayur narsale:

I am able to filter the list when user enter a word in textbox and presses enter key or tab key, but for this solution postback happens.
Is there a way that postback does not happen and the list gets updated dynamically when user keeps typing any character in textbox?



First point is confusing. You don't want postback at all, or you want AsyncPostBack. You can use UpdatePanel.

For the second point, you need to set AutoPostBack 'true' for the TextBox and handle TextChanged event.
https://msdn.microsoft.com/en-us/library/2589b44c(v=vs.85).aspx[^]


这篇关于在vb.net中动态过滤转发器列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆