Value of Cell to equal Cell coloured Green when the same row

PeterWays

New Member
Joined
Jul 21, 2015
Messages
5
Hi Guys,

Is there a way of creating a formula to show the value of which ever cell is coloured Green within a the same row

I have a Spreadsheet has a column to the right that shows the selected value for each row. This value currently is just a simple =A2 value. A2 is then coloured Green to show which value was used.

B2 would have an another value but if its not chosen it would just be left blank for future reference.

Survey 1Survey 2SELECTED RESULTS
20040 (GREEN)50020040 {Formula required}
30005100 (green)5100 {Formula required}

<tbody>
</tbody>





Thanks for all your help
 

Excel Facts

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.
Go to Formulas --> Name Manager --> New
--> In the name box type, CellColorL
--> In the Refers to: box, type, =GET.CELL(63,OFFSET(INDIRECT("RC",FALSE),0,-1)) and select Ok.

Then:


Excel 2010
ABC
1Survey 1Survey 2Result
22004050020040
3300051005100
Sheet1
Cell Formulas
RangeFormula
C2=CHOOSE(VLOOKUP(CellColorL,E2:F3,2,0),A2,B2)
Named Ranges
NameRefers ToCells
CellColorL=GET.CELL(63,OFFSET(INDIRECT("RC",FALSE),0,-1))
 
Upvote 0
Thanks Heaps ben. worked great. What if i wanted it to do it the other way. Say.......

I have a Spreadsheet that a column to the right (THAT IS BLANK) needs to equal the value within the cell along the row that the user selects as green. The cell thats green changes depending on which survey is used for pricing for example.

Its shows the selected green cell value for each row. This formula currently is just a simple '=A2' value. Because A2 is coloured Green to show which value was used.


B2 has an another value but if its not chosen because it would just be left blank for future price comparison reference.

Is there a way of doing this?


Once again thanks in advance.
 
Upvote 0
Can you show an example of what you're looking for in this second example? I don't quite follow. Which columns are we looking through to find the green cell?
 
Upvote 0
Hope this helps explain it

I just need to see how the formula is written and i hope i will able to apply it to a whole template with multiple rows.

I need cells in Column D to have a condition (logical test) to see what is shown. i have given all the different out comes I am after.

Thanks

Excel 2010
ABCD
1Survey 1Survey 2Survey 3SELECTED COST
2$20040$500$4113=A2 [because it is green]
3$3000$51005100=B3 [because it is green]
4=BLANK because there isnt any cells coloured green and no values
5512151134551=TEXT "select one"

<tbody>
</tbody>
 
Upvote 0
Try this:


Excel 2010
ABC
1Survey 1Survey 2Result
22004050020040
3300051005100
4
551215113Select One
Sheet1
Cell Formulas
RangeFormula
C2=IF(AND(CellColorL=10,CellColor2L=10),"Select One",IF(CellColorL=10,B2,IF(CellColor2L=10,A2,"")))
Named Ranges
NameRefers ToCells
CellColor2L=GET.CELL(63,OFFSET(INDIRECT("RC",FALSE),0,-2))
CellColorL=GET.CELL(63,OFFSET(INDIRECT("RC",FALSE),0,-1))
 
Upvote 0
Hi Ben, Thanks That works if I have only a few cells of values and a few Rows. Say if I have 7 survey values and Multiple Rows??

Is there a way of make it more easier to use and apply to multiple Rows and even drag the formula down and for it still to work?
 
Upvote 0
Honestly PeterWays,

This isn't a very robust formula. It's a workaround using an obsolete formula GET.CELL, because there is no formula that returns fill color. You're not going to get the same kind of functionality that you would with normal functions. Can I ask why you would want to calculate based on the color green? What determines which cells get shaded green, and maybe we can use that same logic in the formula instead of chasing after the fill color?
 
Upvote 0
unfortunately it is a user selected. the logic behind which cell is green (selected) is based on a number of things. EG value, inclusions & exclusions in the quote. (things that aren't easily put into a formula) what if we use another way of showing the selected cell (instead of the green)

Thanks
 
Upvote 0
Something like this would certainly be a lot easier to work with:


Excel 2010
ABC
1Survey 1Survey 2Selected Survey
2200405001
3300051002
Sheet1
 
Upvote 0

Forum statistics

Threads
1,214,587
Messages
6,120,405
Members
448,958
Latest member
Hat4Life

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top