This example shows how to aggregate data by the field's first value.
- Form1.cs (VB: Form1.vb)
- Program.cs (VB: Program.vb)
- FirstValueFunction.cs (VB: FirstValueFunction.vb)
This example adds the FirstValue([ProductName])
expression to the First Sold Product field. The expression returns the first sold product by Sales Persons in each product category.
Data Field | Expression |
---|---|
First Sold Product | FirstValue([ProductName]) |
Call the CriteriaOperator.RegisterCustomFunction method to register a custom function in your project (see Program.cs/Program.vb)
Pivot Grid for Web Forms - How to Aggregate Data by the Field's First Value