Detect a background color in SAP

Hello everybody,

I have a question regarding automation activities. I am designing a process for SAP automation. Now have to make a decision based on a background color. If it is red (its a failure) RPA has to do different action as it isn´t red. How can I solve this? How can I grab such a color on screen and bring it to a boolean variable. Problem is, that the red background color can move in table.

firstly, capture the row using "find element“

then go to “Edit Selector” and open ui explorer

then on the bottom left side you will see a property explorer

check if there is a “color” property here

If there is such a property, you can extract it by using the “get attribute” activity



Hello Andreas,
as far as I can see is this a list of labels. To detect the background color you can use the ColorIndex property of the SAP GUI Scripting API. At this point you have to leave UiPath and work with a script. If this is acceptable for you, you can find an approach to use SAP GUI Scripting via an external script here.
Best regards

1 Like

Hi andreas,

Could you solve this problem?

HI @Emine_Kaya1

Please use the latest UiPath Studio, where we have Expose ColorIndex for SAP ALV Tables

We have introduced a new attributes ColorIndex / ColorIntensified / ColorInverse, which allows to identify the background colour of elements.

Best regards, Lev


This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.