web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Help with inline color...
Power Apps
Unanswered

Help with inline color in Gallery

(0) ShareShare
ReportReport
Posted on by 48

Hello good day, I ask you a question, is it possible to define a two-color for a gallery of records, that is, I have 4 records and I would like to have a white color and another medium gray so that the user can detect the difference between the two records and what be so that white is interspersed with gray depending on whether the records grow or not.

I would appreciate it if you could help me

Categories:
I have the same question (0)
  • zmorek Profile Picture
    3,272 on at

    Do you mean like banded rows, where one row is one color, and the next row is another color, alternating?

     

    Assuming the rows have sequential IDs (i.e. nothing has been deleted from the data source), you can use this on the TemplateFill property of a gallery:

     

    If(Mod(ThisItem.ID,2)=0,White,GhostWhite)

  • Richard95 Profile Picture
    48 on at

    I have a sql view that brings back logs.

     

    if I meant a band of rows with a different color

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @Richard95 

    In the TemplateFill property of the gallery, If(ThisItem.IsSelected, LightGrey, White)

    You can also have different colors depending on a field in the records, something like

    Switch(ThisItem.Status, "Active", Red,"Inactive", Grey, "Pending", Coral)

  • Richard95 Profile Picture
    48 on at

    ok this works, but I would like to have the stripes that do not depend on a record, I want the first record to be loaded to be white and the second to be light gray and from then on continue interspersed one white and one gray

  • Verified answer
    Drrickryp Profile Picture
    Super User 2024 Season 1 on at
  • Richard95 Profile Picture
    48 on at


    could you help me to integrate

     

    SortByColumns(

    Search(
    [@'[dbo].[APP_Nipon]'];
    TextSearchBox1.Text;
    "BodegaEntrada";
    "BodegaSalida";
    "DescItem"
    );
    "Numero";
    If(
    SortDescending1;
    Ascending;
    Descending
    )
    )

     

    this code with this new

    With(
    {
    records:'[dbo].[APP_Nipon]'
    };
    ForAll(
    Sequence(CountRows(records));
    Patch(
    Last(
    FirstN(records;Value));
    {rowNumber: Value}
    )
    )
    )

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard