Click here to Skip to main content
11,409,801 members (60,812 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: C# WPF DataGrid

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
I am thinking of making this calculation by pressing the button, and not when enter the data in column A.

Any ideas?

Posted 11-Nov-11 12:37pm
Edited 11-Nov-11 23:32pm
SAKryukov at 12-Nov-11 1:26am
Well, nothing wrong with that, but also nothing special; this is like in a spreadsheet. So, what's the problem?
Dimitris Nemtsov at 12-Nov-11 2:19am
Exactly like excel spreadsheet, I,ve searched all over the .net but didn't find anything usefull.. Ant suggestion or better snippet?

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Itz pretty simple by writing the calculation logic at button_clicked event.
Dimitris Nemtsov at 12-Nov-11 4:20am
Beside, saying itz pretty simple does anyone has a solution to that problem? Or better an example?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 229
1 OriginalGriff 140
2 Maciej Los 138
3 Sascha Lefévre 120
4 BillWoodruff 60
0 Sergey Alexandrovich Kryukov 8,771
1 OriginalGriff 6,905
2 Maciej Los 3,390
3 Abhinav S 3,248
4 Peter Leow 3,059

Advertise | Privacy | Mobile
Web01 | 2.8.150414.5 | Last Updated 12 Nov 2011
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100