srusgaq.blogg.se

Devexpress pivotgrid
Devexpress pivotgrid










devexpress pivotgrid

Public static HtmlString ReportWithPivot( this DataTable source, string cssClass,ĭataTable dt = p.PivotData(rowField, dataField, aggregate, columnFields) (cssClass, rowField, dataField, aggregate, columnFields) String rowField, string dataField, AggregateFunction aggregate, params string columnFields) Then, you can directly use the code in your view as follows:Ĭopy Code public static HtmlString ReportWithPivot( this IEnumerable source, string cssClass, To use the code, you just need to add the reference to the ReportControl assembly. For now, please have a look at the basic pivoting with a simple grid/report control. I may provide many different options to pivot in this article in future. But those samples can easily be derived the same way as it is provided in the previous article. To keep the article simple and due to lack of time, I have not provided many samples in this article. In my previous article, I provided many samples to display data in different pivot forms. I, therefore, decided to write a separate article regarding pivoting the data in ASP.NET MVC. BackgroundĪfter my article, Pivoting DataTable Simplified, I got many email requests from the readers that they wish to Pivot the data in ASP.NET MVC too. I have, therefore, created a simple grid control of my own which renders HTML from the IEnumerable. To display the data in UI, a grid control is also required. This article aims to simplify the process of pivoting of data when you have your IEnumerable in your presentation layer. When you have a large amount of data or you wish to visualize data column wise with logical grouping/aggregation, here is the extension method which will help you. Clicking the 'Customer' field header reverses the sort order and displays those customers who purchased the smallest number of items.Displaying data in a pivot form has become an essential part of reporting now a days. Top 10 Customers - MVC Pivot Grid lists top 10 customers, who purchased the biggest number of items.

devexpress pivotgrid devexpress pivotgrid

Clicking the 'Product Name' field header reverses the current sort order and the control displays the least popular products for each customer.

  • Top 2 Products - in this report, MVC Pivot Grid lists the most two popular products for each customer (those that attract the biggest interest).
  • Use the Year and Quarter combo boxes to specify which period should be displayed.
  • Products(Filtering) - in this report, MVC Pivot Grid displays products bought by customers within a year.
  • The volume of orders is given for each product bought by a customer by quarters.

    devexpress pivotgrid

    Customers - in this report, MVC Pivot Grid summarizes orders made by customers during a specific time period.Use Radio buttons to switch between reports. This demo includes a set of reports for analyzing business data.












    Devexpress pivotgrid