Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
xnadeau
 
Posts: n/a
Default Intervals as logical statements


I'm trying to get Excel to determine whether x<=y<=z is true or false,
but it always comes up false when written this way (even if x=1, y=2,
and z=3). I finally ended up with a formula that looked like this:
=if((and(a2<=b2,b2<=c2)),d2,b2). This worked, but there must be a
better way.


--
xnadeau
------------------------------------------------------------------------
xnadeau's Profile: http://www.excelforum.com/member.php...o&userid=28335
View this thread: http://www.excelforum.com/showthread...hreadid=479146

  #2   Report Post  
Bob Phillips
 
Posts: n/a
Default Intervals as logical statements

That is the syntax. What is wrong with conforming to the syntax?

--

HTH

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


"xnadeau" wrote in
message ...

I'm trying to get Excel to determine whether x<=y<=z is true or false,
but it always comes up false when written this way (even if x=1, y=2,
and z=3). I finally ended up with a formula that looked like this:
=if((and(a2<=b2,b2<=c2)),d2,b2). This worked, but there must be a
better way.


--
xnadeau
------------------------------------------------------------------------
xnadeau's Profile:

http://www.excelforum.com/member.php...o&userid=28335
View this thread: http://www.excelforum.com/showthread...hreadid=479146



  #3   Report Post  
MrShorty
 
Posts: n/a
Default Intervals as logical statements


How about the logical function =AND(A2<=B2,B2<=C2) and drop the IF
function completely?


--
MrShorty
------------------------------------------------------------------------
MrShorty's Profile: http://www.excelforum.com/member.php...o&userid=22181
View this thread: http://www.excelforum.com/showthread...hreadid=479146

  #4   Report Post  
Bob Phillips
 
Posts: n/a
Default Intervals as logical statements

It gives a different result, TRUE or FALSE, not what is in B2 or D2

--

HTH

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


"MrShorty" wrote in
message ...

How about the logical function =AND(A2<=B2,B2<=C2) and drop the IF
function completely?


--
MrShorty
------------------------------------------------------------------------
MrShorty's Profile:

http://www.excelforum.com/member.php...o&userid=22181
View this thread: http://www.excelforum.com/showthread...hreadid=479146



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
Count Intervals of 1 Numeric value in a Row and Return Count down Column Sam via OfficeKB.com Excel Worksheet Functions 8 October 4th 05 04:37 PM
Linking two IF statements together trixma Excel Discussion (Misc queries) 2 September 29th 05 06:07 AM
Logical ELSE statements Ruth Excel Discussion (Misc queries) 2 June 23rd 05 03:23 PM
Nested IF statements John Simons Excel Worksheet Functions 14 February 16th 05 06:17 AM
Logical Function - Multiple IF statements vnsrod2000 Excel Worksheet Functions 7 February 4th 05 10:42 PM


All times are GMT +1. The time now is 01:30 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"