gridview行数据绑定prevoius行值 [英] gridview row databound prevoius row value

查看:75
本文介绍了gridview行数据绑定prevoius行值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好...
是否有任何选项可以获取gridview中上一行的单元格值????
请帮我...
详细信息:
在gridview中,我想空白要重复的行值...
这是示例:
--------------------
站点型号
---- ------
bbsr卡车2
bbsr巴士4
bbsr汽车5
我想像这样
------------------------
站点型号
---- ------
bbsr卡车2
巴士4
汽车5

第二行和第三行单元格[0]的值保留为空白...
我正在使用gridview_rowdatabound事件.
我想将当前row.cell [0]的值与prevoius row.cell [0]的值进行比较.
如果两个值都相同,则当前row.cell [0]值保持空白...

有人请帮我...
我需要C#中的代码....
请帮我...
我的处境非常严峻...
请帮助我...

Hello Everybody...
Is there any option to get the cell value of previous row in a gridview????
plz help me...
Details:
In gridview i want to blank the row values which are being repeated...
Here is the example:
--------------------
Site Model No
---- ----- --
bbsr truck 2
bbsr bus 4
bbsr car 5
i want to make like this
------------------------
Site Model No
---- ----- --
bbsr truck 2
bus 4
car 5

The 2nd and third row cell[0] values remain blank...
i''m using gridview_rowdatabound event.
i want to compare current row.cell[0] value with prevoius row.cell[0] value.
If both values becomes same then the current row.cell[0] value remains blank...

Somebody Please help me...
i need the code in c#....
plz help me...
I''m in a very drastic situation...
Kindly help me...

推荐答案

请参阅此
在此与下一行进行比较
我认为您可以进行必要的更改

http://stackoverflow.com/questions/4035856/how-to-get-previous-rows-specific-value-to-compare-with-next-row-value-in-a-gri [
Refer this
here comparision with next row is given
I think you can do necessary changes

http://stackoverflow.com/questions/4035856/how-to-get-previous-rows-specific-value-to-compare-with-next-row-value-in-a-gri[^]

Note : here the code is in vb.net. Have a look at it so that you can get some idea.


这篇关于gridview行数据绑定prevoius行值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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