IF Help

Brass Contributor

So I have a workbook that I need it to update the below data. Normally I could say Pic1 cell B2= Pic 2 cell B10, but I am referencing 1 sheet to 5 different sheets. So for Day 1 I need to know what my head count is on that day which is on Sheet 2. However, the day changes on Pic 2, see on the 2nd picture where it says Day 2, that can be day 1-5 and if I say B2=B10 but it is now day 5 with a different head count, each day is going to be wrong because it will have the same data. 

 

So I need an IF formula that states that in 'Pic 1' cell B2;  IF 'Pic 2' C5=Day 1, then 'Pic 1' B2='Pic 2' B10.

IF 'Pic 2' C5=Day 2, then 'Pic 1' B2='Pic 2' B10 and so on. Each days total head count changes so if Day 1 head count is 210 and Day 2 head count is 215, then on the Day 1 tab cell B2 would equal 210 and on Day 2 cell B2 would equal 215. 

 

I really hope that makes since and thank you in advance.

 

catherine9910_2-1610607753233.png

catherine9910_3-1610607767348.png

 

 

 

2 Replies

@catherine9910 

Afraid that doesn't work such way. Your logic for B2 is like

if C5=Day1 then (B10 from second sheet) else previous value

But Excel doesn't keep the history of values in cell and doesn't know what was in cell before (if only don't do that programmatically with VBA). 

Better if you have in second sheet columns for all 5 days and take data from them.

@Sergei Baklan thanks I will try that