WPF DataGrid计算 [英] Wpf datagrid calculations

查看:103
本文介绍了WPF DataGrid计算的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我有一种情况想在WPF DataGrid列中进行一个相当奇怪的计算.
在A列中,我手动输入数据,在B列中,我要进行以下计算:

Hi,

I have a case were I would like to make a rather odd calculation in WPF DataGrid column.
In column A I enter the data by hand and in column B, I would like to make the following calculation:

cell B2 = cell A1 + cell A2


我正在考虑通过按下按钮进行此计算,而不是在A列中输入数据时进行计算.

有什么想法吗?

谢谢


I am thinking of making this calculation by pressing the button, and not when enter the data in column A.

Any ideas?

Thanks

推荐答案

在button_clicked事件中编写计算逻辑就很简单.
Itz pretty simple by writing the calculation logic at button_clicked event.


这篇关于WPF DataGrid计算的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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