ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   if cell falls within range of number (i.e. 2500 to 4999) (https://www.excelbanter.com/excel-worksheet-functions/199250-if-cell-falls-within-range-number-i-e-2500-4999-a.html)

Susan

if cell falls within range of number (i.e. 2500 to 4999)
 
I want to detetermine is a cell falls within a pre-estabished set up ranges.

Cell A1 = 4800
Such as
if quantity is 2500-4999 it should return 1.5%
if quantity is 5000-9999 it should return 1.2%

So this correct answer should return 1.5%



ExcelBanter AI

Answer: if cell falls within range of number (i.e. 2500 to 4999)
 
  1. Open the Excel worksheet and select the cell where you want to display the percentage.
  2. Type the following formula into the cell:

    Formula:

    =IF(AND(A1=2500,A1<=4999),[b]1.5%[/b],IF(AND(A1=5000,A1<=9999),[b]1.2%[/b],"")) 

  3. In this formula, we are using the IF function to check if the value in cell A1 falls within the range of 2500 to 4999. If it does, the formula returns 1.5%. If not, it checks if the value falls within the range of 5000 to 9999. If it does, the formula returns 1.2%. If the value in cell A1 does not fall within either of these ranges, the formula returns an empty string ("").
  4. Press Enter to apply the formula to the cell.
  5. The cell should now display the corresponding percentage based on the value in cell A1. In this case, since the value in cell A1 is 4800, the formula returns 1.5%.

That's it! You can now use this formula to determine the percentage for any value that falls within your pre-established set of ranges.

Pete_UK

if cell falls within range of number (i.e. 2500 to 4999)
 
What do you want to happen if the value in A1 is less than 2500 or
greater than 9999?

Pete

On Aug 18, 5:17*pm, Susan wrote:
I want to detetermine is a cell falls within a pre-estabished set up ranges.

Cell A1 = 4800
Such as
if quantity is 2500-4999 it should return 1.5%
if quantity is 5000-9999 it should return 1.2%

So this correct answer should return 1.5%



Mike H

if cell falls within range of number (i.e. 2500 to 4999)
 
Susan,

Format the cell with this in as percentage

=IF(AND(A1=2500,A1<=4999),1.5%,IF(AND(A1=5000,A1 <=9999),1.2%,"Outside of
range"))

Mike

"Susan" wrote:

I want to detetermine is a cell falls within a pre-estabished set up ranges.

Cell A1 = 4800
Such as
if quantity is 2500-4999 it should return 1.5%
if quantity is 5000-9999 it should return 1.2%

So this correct answer should return 1.5%




All times are GMT +1. The time now is 10:03 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com