'Value_If_True' vs. 'Value_If_False'

B

Brenner

How do I reference other cells in the "Value If True" and "Value If False"?

Example: Formula is in A10 and it reads like this...
=IF(A5=TODAY(),B10=25,C10=50)

So - if A5 is equal to Today(), then the # 25 will be placed in B10. If the
A5 is not equal to Today(), then the # 50 will be placed in C10.

When I'm typing in the formula - it seems that all the cells are referenced
as I type them in both the 'value_if_true' spot and the 'value_if_false' spot
in the formula - but the result is ALWAYS --> A5 = FALSE. That's all I ever
get. False in the original cell.

Kindest Regards,
John Brenner
 
D

Dave Peterson

Formulas return values to the cells that contain the formulas.

They can't change other cells.

So you could put this in B10:
=if(a5=today(),25,"")

and this in C10:
=if(a5=today(),"",50)
 
F

FSt1

hi
formulas return values, they cannot put value in other cells.
if you want B10 to be 25, then you will have to put a formula in B10.......
=if(A5=TODAY(),25,"something else")
and a formula in C10....
=if(A5=TODAY(),50,"something else")

regards
FSt1
 
B

Brenner

Thank you for the reply.

My problem is that B10 and C10 are actually values in a series on a chart.
They MUST be blank until the moment that the formula is evaluated.

I have all of my current percentages in a single column, and I need to
automatically move those percentages to the column of cells under the column
titled 9/29/08, and tomorrow when I open the spreadsheet, I need for the
current percentages to automatically move to the column 9/30/08.

If I put the formula in the B10 or C10, they will register as '0' (zero)
whenever the value is false.

Any other ideas?

Thanks,
John
 
F

FSt1

hi
you're not going to do it with a formula but a workbook_open macro might do
the trick.
but we need to know more about the column of percents and how to id the
current column to transfer the values to B10 and C10.

regards
FSt1
 
S

ShaneDevenshire

Hi,

Depending on how you are plotting your data, a formula in the cell may be a
problem even if it return "". The code to do what you want look like

Sub Update()
If Sheet1.[A5] = Date Then
[B10] = 25
[C10] = 50
End If
End Sub

However, I suspect you're not telling us everything so the macro above is of
limited or no use.
 
B

Brenner

Across the top in Row 1, I have dates from Column C (9/15) to Column AN
(10/15). In Column B I have the 'current percent complete' that is linked
back to worksheets that are updated by each one of the 15 manufacturing
teams. Since column B is always current, I can go to the sheet each day and
just key in the 15 percentages in the column for 'today', but I was sick on
Friday and the functional managers went nuts. Go figure. So - what I'm trying
to do, is make it to where anyone can open the worksheet and have the values
from Column B auto-populated into the column that is = to today().

I'm going to try the macro that you suggested - but even if it doesn't work,
I appreciate very much your response. FSt1 and Dave - thank you, too!

Regards,
John




--
Cool


ShaneDevenshire said:
Hi,

Depending on how you are plotting your data, a formula in the cell may be a
problem even if it return "". The code to do what you want look like

Sub Update()
If Sheet1.[A5] = Date Then
[B10] = 25
[C10] = 50
End If
End Sub

However, I suspect you're not telling us everything so the macro above is of
limited or no use.

--
Thanks,
Shane Devenshire


Brenner said:
How do I reference other cells in the "Value If True" and "Value If False"?

Example: Formula is in A10 and it reads like this...
=IF(A5=TODAY(),B10=25,C10=50)

So - if A5 is equal to Today(), then the # 25 will be placed in B10. If the
A5 is not equal to Today(), then the # 50 will be placed in C10.

When I'm typing in the formula - it seems that all the cells are referenced
as I type them in both the 'value_if_true' spot and the 'value_if_false' spot
in the formula - but the result is ALWAYS --> A5 = FALSE. That's all I ever
get. False in the original cell.

Kindest Regards,
John Brenner
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top