A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

How to write an `IF` and an `OR` formula



 
 
Thread Tools Display Modes
  #11  
Old October 4th, 2009, 02:35 PM posted to microsoft.public.excel.worksheet.functions
Jacob Skaria
external usenet poster
 
Posts: 5,952
Default How to write an `IF` and an `OR` formula

Have you tried the below formula Mike has posted ?

=IF(OR(H751,I751),"A","")

In general

'AND() returns true only if all conditions are satisfied
=IF(AND(condition1,condition2,...), TRUE statement, FALSE statement)

'OR() returns true if any one of the condition is met
=IF(OR(condition1,condition2,...), TRUE statement, FALSE statement)

If this post helps click Yes
---------------
Jacob Skaria


"Romileyrunner1" wrote:

Still stuck! Can anyone help.
Need to know .....
If either statement is true then put an "A", otherwise leave blank.
Thanks

"Romileyrunner1" wrote:

Hi Mike,
I actually mean
"If either are true" then put in an "A" (that is, they don`t have to both be
true)
Thanks RR1


"Mike H" wrote:

Hi,

The correct syntax for or is

=IF(OR(H751,I751),"A","")

But in your question you say if BOTH are false so do you mean AND

=IF(AND(H751,I751),"A","")

Mike

"Romileyrunner1" wrote:

Hi,
I want to write the following: (but this doesn`t work)

=IF(H751, OR I751,"A",(""))

Meaning, If value in H75 1 OR if value in I751, then put in an `A`
otherwise if both statements are false, then leave blank.
Any ideas guys?
Thanks

RR1


  #12  
Old October 4th, 2009, 02:49 PM posted to microsoft.public.excel.worksheet.functions
Romileyrunner1
external usenet poster
 
Posts: 73
Default How to write an `IF` and an `OR` formula

Thanks Mike.
works fine now.
RR1

"Mike H" wrote:

In that case the OR formula I posted does what you want

Mike

"Romileyrunner1" wrote:

Hi Mike,
I actually mean
"If either are true" then put in an "A" (that is, they don`t have to both be
true)
Thanks RR1


"Mike H" wrote:

Hi,

The correct syntax for or is

=IF(OR(H751,I751),"A","")

But in your question you say if BOTH are false so do you mean AND

=IF(AND(H751,I751),"A","")

Mike

"Romileyrunner1" wrote:

Hi,
I want to write the following: (but this doesn`t work)

=IF(H751, OR I751,"A",(""))

Meaning, If value in H75 1 OR if value in I751, then put in an `A`
otherwise if both statements are false, then leave blank.
Any ideas guys?
Thanks

RR1


  #13  
Old October 4th, 2009, 02:49 PM posted to microsoft.public.excel.worksheet.functions
Romileyrunner1
external usenet poster
 
Posts: 73
Default How to write an `IF` and an `OR` formula

Thnaks for your time Jacob.
Yep, that`s the one.
Cheers
RR1

"Jacob Skaria" wrote:

Have you tried the below formula Mike has posted ?

=IF(OR(H751,I751),"A","")

In general

'AND() returns true only if all conditions are satisfied
=IF(AND(condition1,condition2,...), TRUE statement, FALSE statement)

'OR() returns true if any one of the condition is met
=IF(OR(condition1,condition2,...), TRUE statement, FALSE statement)

If this post helps click Yes
---------------
Jacob Skaria


"Romileyrunner1" wrote:

Still stuck! Can anyone help.
Need to know .....
If either statement is true then put an "A", otherwise leave blank.
Thanks

"Romileyrunner1" wrote:

Hi Mike,
I actually mean
"If either are true" then put in an "A" (that is, they don`t have to both be
true)
Thanks RR1


"Mike H" wrote:

Hi,

The correct syntax for or is

=IF(OR(H751,I751),"A","")

But in your question you say if BOTH are false so do you mean AND

=IF(AND(H751,I751),"A","")

Mike

"Romileyrunner1" wrote:

Hi,
I want to write the following: (but this doesn`t work)

=IF(H751, OR I751,"A",(""))

Meaning, If value in H75 1 OR if value in I751, then put in an `A`
otherwise if both statements are false, then leave blank.
Any ideas guys?
Thanks

RR1


  #14  
Old October 4th, 2009, 02:52 PM posted to microsoft.public.excel.worksheet.functions
Jacob Skaria
external usenet poster
 
Posts: 5,952
Default How to write an `IF` and an `OR` formula

Bob, I have sent you an email @ tiscali.. Not sure whether that is still
valid...

"Bob Phillips" wrote:

G The site looks quite good, but that page was just no help for this
question.

Where are you Jacob, you seem to post quite early my time (UK).

--
__________________________________
HTH

Bob

"Jacob Skaria" wrote in message
...
Bob, from the query I fealt that the OP only seem to have a problem with
OR
function. Should have been...Thanks..

=IF(AND(condition1,condition2,...), TRUE statement, FALSE statement)
=IF(OR(condition1,condition2,...), TRUE statement, FALSE statement)

"Bob Phillips" wrote:


"Jacob Skaria" wrote in message
...
Missed to copy the below..
http://www.excelfunctions.net/ExcelIf.html


Where it says nothing about AND/OR in an IF function!






  #15  
Old October 4th, 2009, 04:19 PM posted to microsoft.public.excel.worksheet.functions
Bob Phillips[_2_]
external usenet poster
 
Posts: 1,562
Default How to write an `IF` and an `OR` formula

No Jacob, this email has stopped delivering some time ago (although oddly I
can send from it!).

Try me on bob at xldynamic dot com (do the obvious).

--
__________________________________
HTH

Bob

"Jacob Skaria" wrote in message
...
Bob, I have sent you an email @ tiscali.. Not sure whether that is still
valid...

"Bob Phillips" wrote:

G The site looks quite good, but that page was just no help for this
question.

Where are you Jacob, you seem to post quite early my time (UK).

--
__________________________________
HTH

Bob

"Jacob Skaria" wrote in message
...
Bob, from the query I fealt that the OP only seem to have a problem
with
OR
function. Should have been...Thanks..

=IF(AND(condition1,condition2,...), TRUE statement, FALSE statement)
=IF(OR(condition1,condition2,...), TRUE statement, FALSE statement)

"Bob Phillips" wrote:


"Jacob Skaria" wrote in
message
...
Missed to copy the below..
http://www.excelfunctions.net/ExcelIf.html


Where it says nothing about AND/OR in an IF function!








 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:07 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.