Hi All,
I am making use of UltraWinGrid in my application. I have a parent band and two child bands in my grid. Now there are some columns in my child bands for which I want the summary in the parent band. I know that we can use summary rows to consolidate the values of a particular column. But the problem is that it doesn't appear as a column in the parent band and instead the summary row appears in the same band itself. So, is there an inherent property in UltraWinGrid which is helpful in achieving such a functionality? I hope my question is not obscure. I would attach a sample screenshot so that you would get a better overview of what my requisite is.
As you can see from the above screenshot, I have two childbands under a parent band. I have columns like estimated, actual and variance in the child band. Now is it possible to sum up all the values of estimated column and show it in the parent band with the same column name? I want similar functionality for actual,variance columns too. How to achieve such a functionality? Any help would be of great use.
Hi,
There's a number of ways you could do this.
The first option seems like the easiest one to me, depending on the calculations you need to perform and assuming that the formula can handle it.
Thank you very much for your reply Mike. I want to know one thing. My columns are dynamic in my datatable and hence there might be any no of columns in my child band.So, I need to loop through each and every column in the child band in order to add it to the parent band. Is there any other way to add the columns in the parent band without looping?
No, you would have to loop.
Ok. I shall be more precise so that you could get my question. Actually, is there a way to do the summary in the parent band for all the columns by default ? (irrespective of the no of columns in the grid). Because the no of columns in my grid is not the same always. So, I just want to know whether we can do the summary by using ultracalcmanager for all the columns by default.....
I'm not sure I understand your question. If your data structure is not known at design-time, then I don't see what the grid has to do with it - you would have to somehow determine which columns are there. Whether you loop through the columns in the grid or the DataSource, I don't see any way around that, unless you can get the information in some other way. There's obviously no way the grid can tell you which column you need to summarize.