Skip to main content
A newer version of this page is available. .

Top-Bottom

  • 2 minutes to read

The Top-Bottom format conditions allow you to highlight a specific number of topmost/bottommost values. You can specify this number as an absolute or percent value.

The following condition types are supported for measures.

Format Condition

Description

Can be applied to

Top N

The Top N format condition allows you to apply formatting to elements whose values are ranked at the top. For instance, the following image displays a Grid dashboard item whose top 3 Extended Price values filled in green.

TopNFormatCondition

Measures

Bottom N

The Bottom N format condition allows you to apply formatting to elements whose values are ranked at the bottom. For instance, the following image displays a Grid dashboard item whose bottom 40 percent Extended Price values are filled in red.

BottomNFormatCondition

Measures

To create the Top-Bottom format condition in code, create the FormatConditionTopBottom class instance and specify the following settings.

Assign the resulting FormatConditionTopBottom object to the DashboardItemFormatRule.Condition property.

How to: Apply Conditional Formatting to Grid Cells using the Top-Bottom and Average Conditions