在按钮单击中访问datagridview的e.rowindex。 [英] Access e.rowindex of datagridview in a button click.
本文介绍了在按钮单击中访问datagridview的e.rowindex。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个datagridview,我有一些复选框,当我选择多个复选框时,价格应该加起来,但我在按钮点击这样做,所以我无法获得data.gridview的e.rowindex我该怎么办?这个??
解决方案
处理CellClick事件然后检查你的e.ColumnIndex,如果索引等于checkboxcolumn索引,plz直接获取e.RowIndex。 / BLOCKQUOTE>
I have a datagridview and i have some checkboxes in it when i select multiple checkboxes the price should be added up,but i am doing this in a button click so i am unable to get e.rowindex of datagridview how can i do this??
解决方案Handle the CellClick event and then check your e.ColumnIndex, if the index is equal to the checkboxcolumn index, plz directly fetch e.RowIndex.
这篇关于在按钮单击中访问datagridview的e.rowindex。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文