Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 24
Default IF and OR nested function

I need to test a cell to see if the cell is blank or if the value is < 0.
Trying:

=IF((OR(A2="",A2<0),1,0)) should return 1 if it is blank or less than 0 and
0 if cell contains a value 0.

Keep getting an error.

Can you tell me where I am going wrong?

Thanks,
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,440
Default IF and OR nested function

What error do you get?

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"Jon M" wrote in message
...
I need to test a cell to see if the cell is blank or if the value is < 0.
Trying:

=IF((OR(A2="",A2<0),1,0)) should return 1 if it is blank or less than 0
and
0 if cell contains a value 0.

Keep getting an error.

Can you tell me where I am going wrong?

Thanks,


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default IF and OR nested function

Hi,

It was a parenthesis problem

=IF(OR(A2="",A2<0),1,0)

or to take care of text

=IF(OR(A2="",ISNUMBER(A2<0)),1,0)

Mike

"Jon M" wrote:

I need to test a cell to see if the cell is blank or if the value is < 0.
Trying:

=IF((OR(A2="",A2<0),1,0)) should return 1 if it is blank or less than 0 and
0 if cell contains a value 0.

Keep getting an error.

Can you tell me where I am going wrong?

Thanks,

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 24
Default IF and OR nested function

great, thanks!


"Mike H" wrote:

Hi,

It was a parenthesis problem

=IF(OR(A2="",A2<0),1,0)

or to take care of text

=IF(OR(A2="",ISNUMBER(A2<0)),1,0)

Mike

"Jon M" wrote:

I need to test a cell to see if the cell is blank or if the value is < 0.
Trying:

=IF((OR(A2="",A2<0),1,0)) should return 1 if it is blank or less than 0 and
0 if cell contains a value 0.

Keep getting an error.

Can you tell me where I am going wrong?

Thanks,

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nested if function Steve M Excel Worksheet Functions 13 February 29th 08 10:01 PM
Nested IF Function Marco Margaritelli Excel Worksheet Functions 7 July 31st 06 07:54 AM
can you nested sum and round function within if function? anna Excel Worksheet Functions 4 May 27th 06 06:06 AM
Offset function with nested match function not finding host ss. MKunert Excel Worksheet Functions 1 March 21st 06 10:46 PM
Nested IF Function, Date Comparing, and NetworkDays Function carl Excel Worksheet Functions 2 December 29th 04 09:57 PM


All times are GMT +1. The time now is 03:15 PM.

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

About Us

"It's about Microsoft Excel"