Excel Automation: 'Get Cell Color' Not Working Properly

Hi!

I have the flow below, Main.xaml (19.6 KB) , which is supposed to read the color of all specified cells in all rows. If the color “pink” is read, the output should be a “F” however, if the color pink is not read, it should give an output of “C” in the very last column. However, currently, when I run the process, it gives all outputs as “C”. What can I do to improve my process? Excel as attached;Book2.xlsx (9.4 KB)

Any help would be appreciated greatly!

Best Regards,

Hello @h2000!

It seems that you have trouble getting an answer to your question in the first 24 hours.
Let us give you a few hints and helpful links.

First, make sure you browsed through our Forum FAQ Beginner’s Guide. It will teach you what should be included in your topic.

You can check out some of our resources directly, see below:

  1. Always search first. It is the best way to quickly find your answer. Check out the image icon for that.
    Clicking the options button will let you set more specific topic search filters, i.e. only the ones with a solution.

  2. Topic that contains most common solutions with example project files can be found here.

  3. Read our official documentation where you can find a lot of information and instructions about each of our products:

  4. Watch the videos on our official YouTube channel for more visual tutorials.

  5. Meet us and our users on our Community Slack and ask your question there.

Hopefully this will let you easily find the solution/information you need. Once you have it, we would be happy if you could share your findings here and mark it as a solution. This will help other users find it in the future.

Thank you for helping us build our UiPath Community!

Cheers from your friendly
Forum_Staff

Hi!

Looking at the workflow, you commited some mistakes:

  • The index is not being added correctly: '"A12"+index.ToString' returns “A120”.
    Instead, in each “Get Cell Color” you need to use: "A"+(index+12).ToString

  • Each time you get the cell color, the “Color” variable assumes the color of the cell being checked, which means the robot was only checking really for “I” column in the end. So, for each cell you need to check the color and print the result.

  • To check the color of the cell in the “IF” statement, you need to use Color.Name = "Pink"

I made the adjustments and i’m attaching the correct file here for you:
Main.xaml (28.9 KB)

Hope it helps!
Best Regards,

Thank you so much @Marcelo_Guimaraes! This was very helpful to me! I never realised I could make the workflow as such! Thanks!

Best Regards,

1 Like

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