+ Reply to Thread
Results 1 to 9 of 9

Excel for calculating charges min. max. cap

  1. #1
    Registered User
    Join Date
    04-21-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    6

    Excel for calculating charges min. max. cap

    hi all experts,

    i need this very urgently.

    i need a code to calculate the amount of charges and if the value is < 5 the value will be 5 and if it is over 50, it is cap at max 50.

    the % is 0.03125.

    this code will calculate the amount of charges.

    for example, if user type in 10,000. the code will calculate 10000 x 0.03125% and the value is 3.125 but i need the value to be shown as 5 (min. cap at 5).

    if user type in 300,000. the code will calculate 300,000 x 0.03125% and the value is 93.75 but i want the value to be cap at 50.

    please assist. thank you.
    Last edited by mojokid; 04-23-2012 at 03:51 AM.

  2. #2
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Excel for calculating charges min. max. cap

    Something like

    =MIN(50,MAX(5,B2*C2))

  3. #3
    Registered User
    Join Date
    04-21-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Excel for calculating charges min. max. cap

    hi mate,

    thank you for your reply.

    i am a excel noob.

    i need the whole code with the formula of the calculation.

    please help me.

    thank you

    very much appreciated.

  4. #4
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Excel for calculating charges min. max. cap

    That is the "whole code".
    Put your 10,000 or 300,000 in cell B2
    Put the 0.03125% in cell C2
    Put the formula I gave you in some other cell

  5. #5
    Registered User
    Join Date
    04-21-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Excel for calculating charges min. max. cap

    hi mate,

    it need the result to show

    e.g. 46.87 when user type in 150,000 or 18.75 when user type in 60,000.

    very close...

    help thank you!

  6. #6
    Registered User
    Join Date
    04-21-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Excel for calculating charges min. max. cap

    hi mate,
    i got it

    U R GOD!!!!!!

  7. #7
    Registered User
    Join Date
    04-21-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Excel for calculating charges min. max. cap

    hi mate, thank you for the code.

    now i have a minor problem. i have 5 colomns and rows for my codes.

    the problem comes when i dont key in anything into the field and the default value 5 will be there and it affects my total fees calculation in the end.

    i need something like, if value = not filled in by user, the charges dont show anything.

    Please help me

    thank you!

  8. #8
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Excel for calculating charges min. max. cap

    Put an IF() test around the formula:

    =IF(C2="","",MIN(50,MAX(5,B2*C2)))

  9. #9
    Registered User
    Join Date
    04-21-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: Excel for calculating charges min. max. cap

    Thank u mate, I will try again tomorrow.

    Thank u a million

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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