SAP Home Learn Build Integrate Model Operate Extend with AI ConnectTutorial navigator Knowledge Graph API Devtoberfest Developer Advocates App Space

Manage my Account SAP Devs YouTube ↗ Learnings ↗ Community ↗ Provide Feedback ↗
Logout
⤢ Open full site

15 - Implement Conditional Formatting to Change Color Based on Data

Amend the shopping cart page - to highlight any items that have a Unit Quantity of 50 or higher – as part of the SAP Build CodeJam.

Overview

🎓 beginner 15 min. SAP BuildBeginnerSAP Business Technology PlatformSAP Build AppsSAP Build Process Automation

You will learn

  • How to use a formula to change a row background color.
Ian Thain I Ian Thain December 4, 2025
Created by January 2, 2025
Contributors

Prerequisites

Prerequisites

Steps

Intro

In this exercise, you will be enhancing the Cart page of the SAP Build CodeJam app with data and functionality.

Specifically, you will change the background color of the row showing the cart entries. If the quantity ordered is less than 5 the color will be white, and if it is 5 or more the background color will be changed to amber.

Step 1 Amend the Cart Page

  1. Open the Cart page.

  2. Select the Row - Items component.

    Row - Cart Item
    Row - Cart Item

  3. In the Style tab, click on the Background color, likely set to Home.

    Background color
    Background color

  4. Select the NEW PALETTE item.

    New Palette Item
    New Palette Item

  5. Select Formula.

    Edit Formula
    Edit Formula

    Then click the existing formula, which is just a string representing a color.

    Open formula editor
    Open formula editor

    Enter the following formula:

    JavaScript
    IF(repeated.current.quantity > 4, "#f0ab00", "#f7f7f7")

    Edit Formula
    Edit Formula

    Click Submit, and then save your formula by clicking Convert.

    Edit Formula
    Edit Formula

  6. Click Save (upper right).

Step 2 Test the App
+

Resources

Discussion

Share feedback on this tutorial or join the conversation in SAP Community.

Submit detailed feedback Discuss in Community
Steps
Step 1 of 2
1. Amend the Cart Page 2. Test the App

Learn more →