-/+ forumla

G

gma

ok....i have a need for a forumla that will increase and decrease as the
value in another cell goes up or down. i.e.
A1 set number of 95
B1 number is 96
C1 the formula shows 1
if the number in B1 changes to 94 then C1 showns a -1

can some one help me?
 
G

gma

its a little more complicated then that. as the number goes up or down 94(B1)
i need the to formula to calulate plus or minus off a base number 95(A1) in
C1 i.e. A1 is base 95
if the number in B1 is 94 than C1 goes to -1; 93 C1 goes to -2 and so forth
if the number in B1 is 96 than C1 goes to 1; 97 C1 goes to 2 and so forth
 
S

stevefromnaki

Actually Gary's Student is correct. In C1 put "=B1-A1+ works and returns the
correct number according to your examples.

For something more compl;icated try an "if" formular.
If number in B1 > A1 use B1-A1,
If number in B1 < A1 use B1-A1 (this is the same as it returns the same
result if B1 is above or below A1, try it out...

I.e. =if(B1>=A1, B1-A1, B1-A1)

Cheers,
stevefromnaki
 
G

gma

i was over thinking this....this works thanks.

stevefromnaki said:
Actually Gary's Student is correct. In C1 put "=B1-A1+ works and returns the
correct number according to your examples.

For something more compl;icated try an "if" formular.
If number in B1 > A1 use B1-A1,
If number in B1 < A1 use B1-A1 (this is the same as it returns the same
result if B1 is above or below A1, try it out...

I.e. =if(B1>=A1, B1-A1, B1-A1)

Cheers,
stevefromnaki
 

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

Similar Threads

Adding Cells, Get Error. 2
Deletion Of Cells 1
ratio using DATEDIF function 2
increasing or decreasing a cell 16
gain-loss 5
Nameing a function 1
SUMIF "value if false" not working 2
Test within a range? 3

Top