Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
=IF(A1 = 1 #OR#2,1,2)
What is the correct way to write the OR part of the formula? Thanks |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
One way:
=IF(OR(A1=1,A1=2),1,2) Another: = 2 - OR(A1=1,A1=2) In article <51 , TeeSee wrote: =IF(A1 = 1 #OR#2,1,2) What is the correct way to write the OR part of the formula? Thanks |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
=IF(OR(A1=1,A1=2),1,2)
-- Kevin Backmann "TeeSee" wrote: =IF(A1 = 1 #OR#2,1,2) What is the correct way to write the OR part of the formula? Thanks |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
TeeSee,
=IF(OR(A1=1,A1=2),1,2) HTH, Conan "TeeSee" wrote in message ... =IF(A1 = 1 #OR#2,1,2) What is the correct way to write the OR part of the formula? Thanks |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
=IF(OR(A1=1,A1=2),100,200)
Means: If A1 =1 or A1 =2 Then the result is 100, Else the result is 200 -- Kind regards, Niek Otten Microsoft MVP - Excel "TeeSee" wrote in message ... | =IF(A1 = 1 #OR#2,1,2) | | What is the correct way to write the OR part of the formula? Thanks |
#6
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
=IF(OR(A1=1,A1=2),1,2)
Note: this will return 1 if A1 is either 1 ot 2 and 2 if A1 is anything other than 1 or 2. Is that what you want? Maybe =IF(A1=1,1,IF(A1=2,2,"")) Gord Dibben MS Excel MVP On Wed, 27 Feb 2008 13:48:33 -0800 (PST), TeeSee wrote: =IF(A1 = 1 #OR#2,1,2) What is the correct way to write the OR part of the formula? Thanks |
#7
Posted to microsoft.public.excel.misc
|
|||
|
|||
Correct Syntax
Another way:
=If(Or(A1={1,2}),1,2) -- Regards, RD --------------------------------------------------------------------------- Please keep all correspondence within the NewsGroup, so all may benefit ! --------------------------------------------------------------------------- "TeeSee" wrote in message ... =IF(A1 = 1 #OR#2,1,2) What is the correct way to write the OR part of the formula? Thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
SQL syntax | Excel Worksheet Functions | |||
COMPARING DATES with nested IF not working- Syntax is correct though | Excel Discussion (Misc queries) | |||
Correct VBA syntax | Excel Discussion (Misc queries) | |||
what is the correct syntax for an allowable circular reference? | Excel Discussion (Misc queries) | |||
Previous Post - Correct Syntax Query | Excel Worksheet Functions |