ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   IF Function (https://www.excelbanter.com/excel-worksheet-functions/70610-if-function.html)

Ladypep

IF Function
 
I have a range of numbers that I need Excel to perform a function based on
the conditions. The formula I wrote works fine for what I need it to do, but
I can't next beyond 7 expressions. I know someone said I should use LOOKUP to
do this, but I know nothing about the LOOKUP function and I'm not a math
whiz, so I'm lost on that.

Basically, here is the formula that I currently have:

=if(c18=0,0, if(c18<=5, 2.50, if(c18<=10, 5.00, if(c18<=15, 7.50))))

{There is more to the formula, but hopefully that gives the idea}

I have a list of numbers for payments for minutes of transcription that I
need to be able to put in the amount of time transcribed, and have it return
the proper amount.

0-5 minutes = 2.50
5-10 minutes = 5.00
11-15 minutes = 7.50

Et cetera

The problem is this goes up to 55-60 mintues = 30.00

If I could nest more than seven expressions, this would work fine, as it
does the job up to seven. What do you do, though, when you need more than 7?
There is a total of 12 conditions here.
--
Sherry

Ron Coderre

IF Function
 
If your sequence continues in the same progression, try this:

=CEILING(C18/5,1)*2.5

Does that help?

***********
Regards,
Ron

XL2002, WinXP-Pro


"Ladypep" wrote:

I have a range of numbers that I need Excel to perform a function based on
the conditions. The formula I wrote works fine for what I need it to do, but
I can't next beyond 7 expressions. I know someone said I should use LOOKUP to
do this, but I know nothing about the LOOKUP function and I'm not a math
whiz, so I'm lost on that.

Basically, here is the formula that I currently have:

=if(c18=0,0, if(c18<=5, 2.50, if(c18<=10, 5.00, if(c18<=15, 7.50))))

{There is more to the formula, but hopefully that gives the idea}

I have a list of numbers for payments for minutes of transcription that I
need to be able to put in the amount of time transcribed, and have it return
the proper amount.

0-5 minutes = 2.50
5-10 minutes = 5.00
11-15 minutes = 7.50

Et cetera

The problem is this goes up to 55-60 mintues = 30.00

If I could nest more than seven expressions, this would work fine, as it
does the job up to seven. What do you do, though, when you need more than 7?
There is a total of 12 conditions here.
--
Sherry


Bob Umlas, Excel MVP

IF Function
 
You don't need an if function nor a lookup. A direct calculation will do the
job:
=INT((C18+4.9999)/5)*2.5

Bob Umlas
Excel MVP

"Ladypep" wrote:

I have a range of numbers that I need Excel to perform a function based on
the conditions. The formula I wrote works fine for what I need it to do, but
I can't next beyond 7 expressions. I know someone said I should use LOOKUP to
do this, but I know nothing about the LOOKUP function and I'm not a math
whiz, so I'm lost on that.

Basically, here is the formula that I currently have:

=if(c18=0,0, if(c18<=5, 2.50, if(c18<=10, 5.00, if(c18<=15, 7.50))))

{There is more to the formula, but hopefully that gives the idea}

I have a list of numbers for payments for minutes of transcription that I
need to be able to put in the amount of time transcribed, and have it return
the proper amount.

0-5 minutes = 2.50
5-10 minutes = 5.00
11-15 minutes = 7.50

Et cetera

The problem is this goes up to 55-60 mintues = 30.00

If I could nest more than seven expressions, this would work fine, as it
does the job up to seven. What do you do, though, when you need more than 7?
There is a total of 12 conditions here.
--
Sherry


mphell0

IF Function
 

Ron's formula will work unless C18 is 0, so you may need to add an if
statement.

=IF(C18=0,2.5,CEILING(C18/5,1)*2.5)

If 0 should return 0 then just use Ron's formula.


--
mphell0
------------------------------------------------------------------------
mphell0's Profile: http://www.excelforum.com/member.php...o&userid=30153
View this thread: http://www.excelforum.com/showthread...hreadid=510544



All times are GMT +1. The time now is 11:52 PM.

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