Back to Devexpress

PivotGridOptionsViewBase.ColumnTotalsLocation Property

corelibraries-devexpress-dot-xtrapivotgrid-dot-pivotgridoptionsviewbase-419ef8eb.md

latest7.6 KB
Original Source

PivotGridOptionsViewBase.ColumnTotalsLocation Property

Gets or sets the column totals’ location.

Namespace : DevExpress.XtraPivotGrid

Assembly : DevExpress.PivotGrid.v25.2.Core.dll

NuGet Packages : DevExpress.PivotGrid.Core, DevExpress.Win.Navigation

Declaration

csharp
[DefaultValue(PivotTotalsLocation.Far)]
public PivotTotalsLocation ColumnTotalsLocation { get; set; }
vb
<DefaultValue(PivotTotalsLocation.Far)>
Public Property ColumnTotalsLocation As PivotTotalsLocation

Property Value

TypeDefaultDescription
PivotTotalsLocationFar

A PivotTotalsLocation enumeration value which specifies the column totals’ location.

|

Available values:

NameDescription
Near

Column Totals are displayed to the left of the column field values.

| | Far |

Column Totals are displayed to the right of the column field values.

|

Remarks

Use the PivotGridOptionsViewBase.RowTotalsLocation and ColumnTotalsLocation properties to specify the position of Row Totals, Column Totals and Grand Totals. To set both RowTotalsLocation and ColumnTotalsLocation properties simultaneously, the PivotGridOptionsViewBase.SetBothTotalsLocation method can be used.

The following code snippets (auto-collected from DevExpress Examples) contain references to the ColumnTotalsLocation property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-pivot-grid-hide-specific-columns-and-rows/CS/Data.cs#L33

csharp
pivot.OptionsView.ShowRowGrandTotals = false;
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far;
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea;

winforms-pivot-split-field-value-cells/CS/Data.cs#L31

csharp
pivot.OptionsView.RowTotalsLocation = PivotRowTotalsLocation.Far;
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far;
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea;

winforms-pivot-grid-hide-empty-columns-and-rows/CS/Data.cs#L32

csharp
pivot.OptionsView.RowTotalsLocation = PivotRowTotalsLocation.Far;
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far;
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea;

web-forms-pivot-grid-split-field-value-cells/CS/ASPxPivotGrid_SplittingCells/Data.cs#L32

csharp
pivot.OptionsView.RowTotalsLocation = PivotRowTotalsLocation.Far;
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far;
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea;

web-forms-pivot-grid-hide-particular-rows-and-columns/CS/ASPxPivotGrid_HidingColumnsAndRows/Data.cs#L34

csharp
pivot.OptionsView.ShowColumnGrandTotals = false;
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far;
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea;

winforms-pivot-grid-hide-specific-columns-and-rows/VB/Data.vb#L37

vb
pivot.OptionsView.ShowRowGrandTotals = False
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea

winforms-pivot-split-field-value-cells/VB/Data.vb#L35

vb
pivot.OptionsView.RowTotalsLocation = PivotRowTotalsLocation.Far
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea

winforms-pivot-grid-hide-empty-columns-and-rows/VB/Data.vb#L44

vb
pivot.OptionsView.RowTotalsLocation = PivotRowTotalsLocation.Far
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea

web-forms-pivot-grid-split-field-value-cells/VB/ASPxPivotGrid_SplittingCells/Data.vb#L45

vb
pivot.OptionsView.RowTotalsLocation = PivotRowTotalsLocation.Far
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea

web-forms-pivot-grid-hide-particular-rows-and-columns/VB/ASPxPivotGrid_HidingColumnsAndRows/Data.vb#L47

vb
pivot.OptionsView.ShowColumnGrandTotals = False
pivot.OptionsView.ColumnTotalsLocation = PivotTotalsLocation.Far
pivot.OptionsDataField.Area = PivotDataArea.ColumnArea

See Also

PivotGridOptionsViewBase Class

PivotGridOptionsViewBase Members

DevExpress.XtraPivotGrid Namespace