HI,
Just installed the latest release, Q1 2013 SP1 (version 2013.1.321)
RadPivotGrid
- IMPROVED: Exposed a method for accessing cell values.
- FIXED: Unable to open the Filter Popup Dialog when filter items contain DBNULL values.
How do I access the cell values as stated above?
Also is it possible to add a calculation field to a pivot grid?
Cheers
Shaun.
5 Answers, 1 is accepted
Thank you for writing.
You should use the RadPivotGridElement's GetAggregateValue method in order to access cells value. Refer to the method signature:
public
CellAggregateValue GetAggregateValue(IGroup row, IGroup column,
bool
collapsedRow,
bool
collapsedColumn)
The item concerns a Pivot calculations is still not resolved.
Should you have any other questions, do not hesitate to contact us.
Greetings,
Peter
the Telerik team
Thanks for that, do you have a code example as I'm not having much luck accessing the cells.
Cheers
Shaun.
Thank you for writing back.
You can you this method in this way:
this
.radPivotGrid1.UpdateCompleted +=
new
EventHandler(radPivotGrid1_UpdateCompleted);
this
.FillWithData();
}
void
radPivotGrid1_UpdateCompleted(
object
sender, EventArgs e)
{
foreach
(PivotGroupNode columnNode
in
this
.radPivotGrid1.PivotGridElement.GetColumnGroups())
{
foreach
(PivotGroupNode rowNode
in
this
.radPivotGrid1.PivotGridElement.GetRowGroups())
{
CellAggregateValue value =
this
.radPivotGrid1.PivotGridElement.GetAggregateValue(columnNode.Group, rowNode.Group,
false
,
false
);
if
(!
string
.IsNullOrEmpty(value.FormattedValue))
{
//deal with the cell value
}
}
}
}
I hope this is helpful.
Do not hesitate to write back anytime you have further questions or need assistance.
Peter
the Telerik team
Hi
Can be the cell values modified?
Regards,
Paulo
Hello, Paulo,
Currently, RadPivotGrid doesn't allow you to edit the aggregated data.
However, we already have a similar feature request logged in our feedback portal. You can track its progress, subscribe for status changes and add your comments on the following link: https://feedback.telerik.com/winforms/1371023-add-radpivotgrid-end-user-capabilities-for-editing-the-data
I hope this information helps.
Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik