Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

If statement and between

Posted on 2011-03-01
3
295 Views
Last Modified: 2012-05-11
Experts, I need to test if D142 is between I18 and J18.  If so, then return 250 otherwise 0.
is this the correct way to write it?  I am not getting the correct answer.
=IF(I18<$D142<J18,250,0)
0
Comment
Question by:pdvsa
  • 2
3 Comments
 
LVL 81

Accepted Solution

by:
zorvek (Kevin Jones) earned 500 total points
ID: 35012520
=IF(AND($D142>I18,$D142<J18),250,0)

Kevin
0
 
LVL 58

Expert Comment

by:cyberkiwi
ID: 35012523
=IF(AND(I18<$D142,$D142<J18),250,0)
0
 
LVL 58

Expert Comment

by:cyberkiwi
ID: 35012531
And because you said "between"

=IF(AND(I18<=$D142,$D142<=J18),250,0)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question (http:/Q_27311462.html), I created an alternative function to the Excel Concatenate() function that you might find useful.  I tested several solutions and share the results in this article as well as t…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question