ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   How to get a formula result to return either "+", "- ", or "=" (https://www.excelbanter.com/excel-worksheet-functions/446603-how-get-formula-result-return-either-%3D.html)

Scrubber

How to get a formula result to return either "+", "- ", or "="
 
Does anyone know of or how to craft a formula that calculates the difference between the values in two columns, and then returns to a third column either a +, -, or = depending on whether value one is more than, less than or equal to value two?

Thank you!

Spencer101

1 Attachment(s)
Quote:

Originally Posted by Scrubber (Post 1603758)
Does anyone know of or how to craft a formula that calculates the difference between the values in two columns, and then returns to a third column either a +, -, or = depending on whether value one is more than, less than or equal to value two?

Thank you!

Is this what you mean?

I'm sure there are other ways, but this is quick and dirty and it works... ;)

EDIT: You may need to switch it around a little as it compares the value in A against B and I think you want B against A.
Let me know if you need help with that....

Scrubber

Quote:

Originally Posted by Spencer101 (Post 1603760)
Is this what you mean?

I'm sure there are other ways, but this is quick and dirty and it works... ;)

EDIT: You may need to switch it around a little as it compares the value in A against B and I think you want B against A.
Let me know if you need help with that....

Would you mind resending that file as .xls, not .xlsx? Sorry, I cannot open .xls format.

Thank you Spencer!

Jane

Spencer101

1 Attachment(s)
Quote:

Originally Posted by Scrubber (Post 1603765)
Would you mind resending that file as .xls, not .xlsx? Sorry, I cannot open .xls format.

Thank you Spencer!

Jane

Here you go Jane.

I've even swapped it around so it actually does what I presume you meant this time.

If it's NOW the wrong way round, just swap the < for in the formula.

Let me know!

S.

Claus Busch

How to get a formula result to return either "+", "- ", or "="
 
Hi,

Am Wed, 18 Jul 2012 19:01:17 +0000 schrieb Scrubber:

Does anyone know of or how to craft a formula that calculates the
difference between the values in two columns, and then returns to a
third column either a +, -, or = depending on whether value one is more
than, less than or equal to value two?


try:
=IF(B1A1,"+",IF(B1=A1,"=","-"))



Regards
Claus Busch
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2

Scrubber

Quote:

Originally Posted by Spencer101 (Post 1603766)
Here you go Jane.

I've even swapped it around so it actually does what I presume you meant this time.

If it's NOW the wrong way round, just swap the < for in the formula.

Let me know!

S.


EXACTLY! Thank you so very much!

Spencer101

Quote:

Originally Posted by Scrubber (Post 1603771)
EXACTLY! Thank you so very much!

Pleasure was all mine. Glad I could help.

:)


All times are GMT +1. The time now is 10:37 AM.

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