vb.net代码,用于在datagrid中搜索文字 [英] vb.net code for Searching for perticuler text in datagrid

查看:97
本文介绍了vb.net代码,用于在datagrid中搜索文字的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我希望代码在按键事件上搜索数据网格中的特定文本.

Hi
I want a code to search particular text in data grid on key press event.

推荐答案

写道:

我想在按键事件中使用代码搜索数据网格中的特定文本.

I want a code to search particular text in data grid on key press event.



当人们要求这样的特定代码时,我总是很困惑.您不能使用代码来搜索文本,而是自己将其应用于按键事件?

假设您没有数据源,则可以将SQL应用于该数据源(通常这样做),然后遍历单元格并使用Regex或字符串类的方法来查找您的字符串匹配.



I am always confused when people ask for such specific code. You can''t take the code to search for text, and apply it on a key press event yourself ?

Assuming you don''t have a data source you can apply SQL to ( which is what you''d usually do ), you''d iterate over the cells and use Regex or the methods of the string class to find if your string matches, I guess.


这篇关于vb.net代码,用于在datagrid中搜索文字的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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