在网格视图中比较2行 [英] compare 2 rows in grid view

查看:74
本文介绍了在网格视图中比较2行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在DataGridViewRow1(:grdfloopy1)中找到彼此相同且在相同文件域中的行,然后在DataGridViewRow2(:grdfloopy1)中显示这两行.
plzzzzzzzzzzzzzzz很快帮助我:rose::doh::rose::doh::rose::sigh:

i want to find rows in DataGridViewRow1(:grdfloopy1) that are the same az each other in same fileds and then show these 2 rows in DataGridViewRow2(:grdfloopy1).
plzzzzzzzzzzzzz help me soon:rose: :doh: :rose: :doh: :rose: :sigh:

推荐答案

您需要做的是

1.获取网格中的行数

2.循环比较忽略当前行的行数,比较每列.如果有比赛,那就做所有需要的事情.

我个人不会这样.我将从研究数据视图及其过滤功能开始

[edit]由于扫描文字说话,起初不了解要求[/edit]

Google在此
what your going to need to do is

1. get the amount of rows in the grid

2. Loop through the number of rows ignoring the current row, comparing each column. If a match then do what ever is required.

personally I wouldn''t go this way. I''d start by looking into Dataviews and its filtering capabilities

[edit] didn''t understand the requirements at first due to scanning text speak[/edit]

Google shpws plenty of examples on this vb.net Comparing datasets for duplicate rows


这篇关于在网格视图中比较2行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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