ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Difference between 2 numbers (https://www.excelbanter.com/excel-worksheet-functions/257872-difference-between-2-numbers.html)

Alan Ralph

Difference between 2 numbers
 
Hi, I'm looking to calculate the differnce between two numbers, Say I have 24
in a columnand next to it in the next column I have 25, I would like it to
show the differnce of +1 in the next column. Then say the next row down it
has 30 in the first column and 25 in the next it would be a differnce of -5
and so on. Wouls also like the cell to be highted with a colour if its a +
number and a differnt colour if its minus. If both numbers are the same then
would like a 0 and no colour. Hope you can understand what I'm looking for. I
can get it to say true or false but not to show the difference. Hope someone
can help me.
--
Alan

Alan Ralph

Difference between 2 numbers
 
Forgot to say I'm using 2007 edition of Excel.
--
Alan


"Alan Ralph" wrote:

Hi, I'm looking to calculate the differnce between two numbers, Say I have 24
in a columnand next to it in the next column I have 25, I would like it to
show the differnce of +1 in the next column. Then say the next row down it
has 30 in the first column and 25 in the next it would be a differnce of -5
and so on. Wouls also like the cell to be highted with a colour if its a +
number and a differnt colour if its minus. If both numbers are the same then
would like a 0 and no colour. Hope you can understand what I'm looking for. I
can get it to say true or false but not to show the difference. Hope someone
can help me.
--
Alan


Paul C

Difference between 2 numbers
 
the formula is simple
A B C
1 24 25 1
2 30 25 -5

In C1 use =B1-A1

Use Conditional Formatting (look in Excel Help for details) to do the colors
Fill with one color if greater than 0, another if less than 0. If the value
is 0 no Fill would be applied
--
If this helps, please remember to click yes.


"Alan Ralph" wrote:

Hi, I'm looking to calculate the differnce between two numbers, Say I have 24
in a columnand next to it in the next column I have 25, I would like it to
show the differnce of +1 in the next column. Then say the next row down it
has 30 in the first column and 25 in the next it would be a differnce of -5
and so on. Wouls also like the cell to be highted with a colour if its a +
number and a differnt colour if its minus. If both numbers are the same then
would like a 0 and no colour. Hope you can understand what I'm looking for. I
can get it to say true or false but not to show the difference. Hope someone
can help me.
--
Alan


Roger Govier[_8_]

Difference between 2 numbers
 
Hi Alan

Supposing we have the data in columns A and B then the formula in C1 is
=B1-A1

You could just format the column, FormatCellsNumberRed Negative
--
Regards
Roger Govier

Alan Ralph wrote:
Hi, I'm looking to calculate the differnce between two numbers, Say I have 24
in a columnand next to it in the next column I have 25, I would like it to
show the differnce of +1 in the next column. Then say the next row down it
has 30 in the first column and 25 in the next it would be a differnce of -5
and so on. Wouls also like the cell to be highted with a colour if its a +
number and a differnt colour if its minus. If both numbers are the same then
would like a 0 and no colour. Hope you can understand what I'm looking for. I
can get it to say true or false but not to show the difference. Hope someone
can help me.


Alan Ralph

Difference between 2 numbers
 
Thanks Paul I was trying it by difference, you made it so easy I should have
thought of it. done the colour conditioning too thanks again.
--
Alan


"Paul C" wrote:

the formula is simple
A B C
1 24 25 1
2 30 25 -5

In C1 use =B1-A1

Use Conditional Formatting (look in Excel Help for details) to do the colors
Fill with one color if greater than 0, another if less than 0. If the value
is 0 no Fill would be applied
--
If this helps, please remember to click yes.


"Alan Ralph" wrote:

Hi, I'm looking to calculate the differnce between two numbers, Say I have 24
in a columnand next to it in the next column I have 25, I would like it to
show the differnce of +1 in the next column. Then say the next row down it
has 30 in the first column and 25 in the next it would be a differnce of -5
and so on. Wouls also like the cell to be highted with a colour if its a +
number and a differnt colour if its minus. If both numbers are the same then
would like a 0 and no colour. Hope you can understand what I'm looking for. I
can get it to say true or false but not to show the difference. Hope someone
can help me.
--
Alan



All times are GMT +1. The time now is 02:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com