Hello,

I have an inventory excel spreadsheet I'm working on. In a worksheet called 'Inventory Analysis' I have a column G (values starting at G5) with which I used conditional formatting to highlight the 5 lowest values. I want to create another worksheet in which I can utilize a formula to choose the 5 rows in 'Inventory Analysis' that have the highlighted cell color in column G (which is RGB (218, 238, 243)) and paste it to this new worksheet.

The other thing is that I do not want to copy/paste every column of the selected row. Is there a simple way to do so via function? Or is VBA the way to go?


Here is a sample function I used on a separate worksheet that is similar to what I want to do.

=IFERROR(INDEX('Inventory Analysis'!B:B, MATCH(A5, 'Inventory Analysis'!A:A, FALSE), 1),"")

I am wondering if there is a way to tweak this function so that it uses the cell color to find values.

Thank you guys for any help.