>is there a way to total a column when using grid controls, if not, recommendations?
>
>fc
Frank,
If that's a running total you could do that with the addition of a calculated field. Your calculation routine sould be wise enough to only change the totals of current row and the rest.
If that's column total, then you would do it by placing a textbox control below the grid. Again there is a way to prevent lengthy recalculation anytime column value changes. Suppose you have parent-child form and grid is for child. Child records could be many. Using plain sum each time the value changes would be time consuming. Instead :
-Do a totaling once each time parent changes. An SQL sum to array is effective here (under normal circumstances each time parent changes you would be dealing with tableupdated data for the child).
-Place the result into textbox
-Each time column value changes add (postedit - preedit) value to textbox value.
I have been using this technique since 286s were used widely. It provides prompt totaling as column value changes ;)
PS: In a buffered table SQL sum would only sum tableupdated values.
Cetin