正确使用BindingSource的Find方法 [英] Correct use of Find Method of a BindingSource

查看:522
本文介绍了正确使用BindingSource的Find方法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我正在尝试使此代码正常工作,但到目前为止还没有运气,请帮忙!!!

我有以下形式的对象:

具有绑定源的datagridview已填充

上面有一些项目的组合框

执行find方法的按钮

我需要使用什么代码来查找绑定源的字段之一中包含的字符串?绑定源中包含的字符串是在组合框中选择的项目.


谢谢.

Hello All,

I am trying to get this code to work but so far no luck, please help!!!

I have the following objects in a form:

A datagridview with a bindingsource already populated

A combobox with some items on it

A button to execute the find method

What code I need to use to find the string contained in one of the fields of the bindingsource? The string contained in the bindingsource is the item selected in the combobox.


Thanks.

推荐答案

选中此

BindingSource.Filter属性 [
Check this

BindingSource.Filter Property[^]


这篇关于正确使用BindingSource的Find方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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