The if statement is no problem. I guess the issue is that I am
updating the total row with a call to my datagrid object, ie
myDataGrid[totalRowIdx,curCol]=totalValue. The issue is that this
then triggers recursive calls to the columnchanging event and I get
lost in la la land. The crux of the question is, in what event should
do the calculation, and to what should I assign the new value -> the
datagrid or the underlying dataview structure...
"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in message news:<ee**************@TK2MSFTNGP10.phx.gbl>...
Jon,
What I would do is place an if statement around the code that updates
the data grid, updating the total row only if the value that changed was not
the total row itself.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Jon" <jo*@ferrand.com> wrote in message
news:56**************************@posting.google.c om... I have a datagrid with a total row on the bottom. What is the best
method to "instantly" update the total row when the value of any row
changes. I am running into problems when I use the column changed
event to calculate the total and assign it directly to the grid ->
myDataGridObject[totalrow,colIdx]=newTotal. When I do this, more
change events are fired, causing unwanted consequences.