Visual Studio Datagridview - 根据多个条件查找所有行 [英] Visual Studio Datagridview - Finding all rows based on multiple criteria
问题描述
我正在开发一个从文件Blacklist.accdb导入物流公司数据库的应用程序(我是Visual Studio的新手,我还在学习vb.net)
列为:
MCN / DOT ||运营商名称||主要联系人||二次接触||主要电话||辅助电话||传真号码$
目标是让用户能够将字符串插入应用程序的文本框1-7,然后单击"查找"按钮。无论如何,看看他们使用的运营商是否与数据库中的任何运营商有关。
EX:来自用户运营商的电话号码与两个电话号码相匹配Datagridview。现在我们知道用户的运营商可能与发现的运营商有关联。
我目前正在使用"查找"。向后过滤的按钮(最后一行)并删除其中没有任何单元格具有TextBox1.Text或TextBox2.Text或TextBox3.Text等的列 - 这对于处理数百美元的b $ b行时非常缓慢数据。
有没有更快捷的方法呢?
I am working on an application that imports a database of logistics companies from file Blacklist.accdb (I am very new to Visual Studio and am still learning vb.net)
The columns are:
MCN / DOT || Carrier Name || Primary Contact || Secondary Contact || Primary Phone || Secondary Phone || Fax Number
The goal is for the user to be able to insert strings into the application's TextBoxes 1-7, and click "Find" to see if the carrier they are using is related to any of the carriers in the database in anyway.
EX: Phone numbers from the user's carrier matches two phone numbers in the Datagridview. Now we know that the user's carrier is potentially affiliated with the carriers found.
I am currently using a "Find" button which filters backwards (Last row first) and removes columns in which none of the cells have TextBox1.Text or TextBox2.Text or TextBox3.Text etc. - Which works, just incredibly slowly when dealing with hundreds
of rows of data.
Is there a quicker way to do this?
推荐答案
你听说过SQL吗?
这篇关于Visual Studio Datagridview - 根据多个条件查找所有行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!