+ Reply to Thread
Results 1 to 8 of 8

putting a minum in an IF statement calculation

  1. #1
    Registered User
    Join Date
    04-03-2017
    Location
    london
    MS-Off Ver
    Microsoft Office Professional Plus 2014
    Posts
    4

    putting a minum in an IF statement calculation

    Hi, I have the following formula which uses an IF statement to validate whether to perform a calculation and I need to set a minumum value. The formula is:

    =IF(LEFT(A108,3)="cmb",E108*0.05,0)

    If Cell A108 begins with CMB then the rate to apply is E108*0.05 but if E108 is less than 400 I need the result to be 20.

    Any help appreciated

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,203

    Re: putting a minum in an IF statement calculation

    =IF(LEFT(A108,3)="cmb",min(E108*0.05,20),0) should do that.
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  3. #3
    Registered User
    Join Date
    04-03-2017
    Location
    london
    MS-Off Ver
    Microsoft Office Professional Plus 2014
    Posts
    4

    Re: putting a minum in an IF statement calculation

    Hi Glenn, Thanks for replying but it hasn't worked. I put in a value of 350 in e108 and cmb in a108 and it returned a value of 17.50

  4. #4
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: putting a minum in an IF statement calculation

    Try with
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  5. #5
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,481

    Re: putting a minum in an IF statement calculation

    Quote Originally Posted by Glenn Kennedy View Post
    =IF(LEFT(A108,3)="cmb",min(E108*0.05,20),0) should do that.
    I think MAX is more reasonable!
    Quang PT

  6. #6
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,203

    Re: putting a minum in an IF statement calculation

    Bebo. You're right. A senior moment...

    =IF(LEFT(A108,3)="cmb",MAX(E108*0.05,20),0)

  7. #7
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,481

    Re: putting a minum in an IF statement calculation

    another option:

    =(LEFT(A108,3)="cmb")*MAX(E108*0.05,20)

  8. #8
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2021
    Posts
    5,931

    Re: putting a minum in an IF statement calculation

    Or

    =MAX(400,E108)*0.05*COUNTIF(A108,"cmb*")

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. putting a percentage calculation into a chart
    By LLOYD6664 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-18-2016, 08:18 PM
  2. putting if statement in every cell in a column
    By superchew in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 02-12-2015, 04:49 PM
  3. putting an if statement into a cell
    By MP3265 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-27-2013, 06:02 PM
  4. [SOLVED] Conditional statement calculation based on result of previous calculation.(Need some help)
    By takeprofit in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-01-2012, 01:45 AM
  5. Putting a Calculation into text
    By gvb in forum Excel General
    Replies: 10
    Last Post: 02-24-2009, 01:16 PM
  6. putting a simple calculation in a field that may change rows
    By matpj in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-08-2005, 11:55 AM
  7. finding the minum rows name
    By hasimturker in forum Excel General
    Replies: 4
    Last Post: 04-18-2005, 07:59 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1