C#中的Datagridview复选框事件 [英] Datagridview checkbox event in C#

查看:103
本文介绍了C#中的Datagridview复选框事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题:我在使用CheckBox的Win应用程序中使用DataGridView。

CheckBox列有4个不同的列。

其中一列保存Integer值10,20,40,60 ......

我想要...

当用户动态检查或取消选中事件时,CheckBox,

应该添加或减去相应的整数值

即时,价值应立即显示在标签上。

所以,请帮助我。



我能够在button_click事件中进行这些活动,我得到了已检查复选框的整数值的总和

总和,但我想要动态。

解决方案

有关如何捕获复选框事件的几个示例列在:



http://stackoverflow.com / questions / 11843488 / datagridview-checkbox-event [ ^ ]

Problem: I am using DataGridView in a Win Application with CheckBox.
There are 4 different columns along with CheckBox column.
One of these columns holds Integer value like 10, 20, 40, 60...
I want that...
When a user check or uncheck event dynamically a CheckBox,
the corresponding Integer value should be added or subtracted
on the fly and value should be displayed in a label instantly.
So, Please Help me.

I am able to these activities on button_click event, i get the total
sum of integer value of checked checkbox, but i want this on the fly.

解决方案

Several examples of how to capture the checkboxes events are listed at:

http://stackoverflow.com/questions/11843488/datagridview-checkbox-event[^]


这篇关于C#中的Datagridview复选框事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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