Giter Site home page Giter Site logo

devexpress-examples / blazor-dxgrid-conditional-formatting Goto Github PK

View Code? Open in Web Editor NEW
0.0 34.0 2.0 1.52 MB

This example demonstrates how to customize the appearance of Blazor grid elements based on custom conditions.

License: Other

HTML 35.94% C# 64.06%
dxgrid grid blazor blazor-application blazor-grid blazor-server blazor-webassembly customization grid-cell-customization grid-row-customization

blazor-dxgrid-conditional-formatting's Introduction

Grid for Blazor - Customize cell appearance based on custom conditions

The example demonstrates how to customize appearance of DevExpress Blazor Grid elements based on custom conditions.

Grid - Customize Element Appearance

The code example uses summary items to calculate minimum, maximum, and average column values. Based on cell and summary item values, a CustomizeElement event handler changes cell appearance in the following columns:

Discount Column
Cells that display positive values are colored green.

Unit Price Column
All cell values are bold. If a cell value is lower than the column average value, the cell's font color is green; otherwise, it is red.

Quantity Column
If a cell value is lower than the average column value, the cell is colored in a shade of red; otherwise, it is a shade of blue. The more a cell value differs from the average value, the brighter the color. If a cell value is equal to the average value, the color is white.

Total Column
A cell displays one of the following arrows based on its value:

  • A red arrow pointing down - small values.

  • A yellow arrow pointing left - medium values.

  • A green arrow pointing up - large values.

Files to Review

Documentation

blazor-dxgrid-conditional-formatting's People

Contributors

khamlyuk avatar margaritaloseva avatar svetlanamikheeva avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.