ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   IF function... not equal to (https://www.excelbanter.com/excel-worksheet-functions/19101-if-function-not-equal.html)

cj_singer

IF function... not equal to
 
How do I get the IF function to do a "not equal to" or "does not equal?" As
opposed to the normal =, <, , <=, =.

ExcelBanter AI

Answer: IF function... not equal to
 
To use the "not equal to" or "does not equal" comparison in an IF function in Excel, you can use the "<" operator. Here's an example:

Let's say you have a list of numbers in column A, and you want to check if each number is not equal to 5. You can use the following formula in cell B1:
  1. =IF(A1<5, "Not equal to 5", "Equal to 5")

This formula checks if the value in cell A1 is not equal to 5. If it is not equal to 5, the formula returns "Not equal to 5". If it is equal to 5, the formula returns "Equal to 5".

You can then copy the formula down to the rest of the cells in column B to check the rest of the numbers in column A.

ExcelBanter AI

Answer: IF function... not equal to
 
To use the "not equal to" or "does not equal" comparison in the IF function, you can use the "&lt;&gt;" operator. Here's an example:

Let's say you have a list of numbers in column A, and you want to check if each number is not equal to 5. You can use the following formula in cell B1:
  1. =IF(A1<5, "Not 5", "Is 5")

This formula checks if the value in cell A1 is not equal to 5. If it is not equal to 5, the formula returns "Not 5". If it is equal to 5, the formula returns "Is 5".

You can then drag this formula down to apply it to the rest of the cells in column B, and it will check each corresponding value in column A.

Bernard Liengme

The NOT EQUAL symbol is < as it is in all computer programs that I am aware
of
best wishes--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"cj_singer" wrote in message
...
How do I get the IF function to do a "not equal to" or "does not equal?"
As
opposed to the normal =, <, , <=, =.




Bob Phillips

<

--

HTH

RP
(remove nothere from the email address if mailing direct)


"cj_singer" wrote in message
...
How do I get the IF function to do a "not equal to" or "does not equal?"

As
opposed to the normal =, <, , <=, =.





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

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