+ Reply to Thread
Results 1 to 5 of 5

Formula to CAP another value

  1. #1
    Registered User
    Join Date
    02-28-2019
    Location
    Peterborough
    MS-Off Ver
    2013
    Posts
    94

    Formula to CAP another value

    Hi,

    First of all I'm not sure if this needs to be a formula or VBA so apologies.

    I'm looking for some help with a formula that references others cells to calculate how many temporary staff are required based on capping an overtime factor at 17%. I look at how many people are required vs how many available staff. Then from that I calculate overtime hours required to meet a plan. this is the value I want to cap at 17%. for example if it says 25% overtime is required, then I would like this formula in row 60 (temporary Labour) to increase until that % values reduces to 17%. I'm not exactly sure how to explain it clearly enough so I have attach a test document to show my sheet and what the expected results are, along with some description. (Don't worry I have used Random numbers)

    thanks in advance for any support,

    KCroft
    Attached Files Attached Files

  2. #2
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: Formula to CAP another value

    there are some smart folk about who could no doubt do this very simply - but one immediate question for you

    when you determine available HC you're subtracting / excluding # trainers
    yet, when you determine the overtime % (row 71) you're including trainers as though they're available.

    the below suggestion assumes the above is incorrect - i.e. both calcs should be consistent

    below assumes trainers should be excluded from available HC

    C60: =MAX(0,CEILING(((C$57*7)-((C$59-SUM(C$61:C$64))*7*1.17))/(7*1.17),1))
    copied across

    so, in short, I'm saying that in addition to applying above I think row 71 should exclude G64 prior to * 7 ?

    with above changes / formulae in place you would get 0, 1, 4, 6, and 7 temp HC respectively - returning 0%, 17%, 16%, 16% & 17% OT

  3. #3
    Registered User
    Join Date
    02-28-2019
    Location
    Peterborough
    MS-Off Ver
    2013
    Posts
    94

    Re: Formula to CAP another value

    Hi Thanks for the reply.

    I'm including trainers in the overtime % calculation as I am saying overtime is done outside working hours but training is done only during normal working hours. so for overtime trainers would be available to produce. if that makes sense.

    I tried your formula which works a treat if exclude trainers from the % calculation. if I make this modification to your formula, so sum(C$61:C$63)) it returns me a 0. does the whole structure of the formula need to change with what I said above regarding trainers?

    Thanks,

  4. #4
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: Formula to CAP another value

    Hi, so, perhaps the below amendment would suffice?

    C60: =MAX(0,CEILING(((C57*7)-SUM((C59-SUM(C61:C64))*7*1.17,C64*7*0.17))/(7*1.17),1))
    copied across

    the above basically just establishes amount of available hours using existing HC {incl. max of 17% OT for Trainers}

    obviously the reference to 17% could be modified to cell reference; I missed that.

  5. #5
    Forum Expert XLent's Avatar
    Join Date
    10-13-2010
    Location
    Northumberland, UK
    MS-Off Ver
    various
    Posts
    2,704

    Re: Formula to CAP another value

    updated above for B74 requirement (flexing %)

    =MAX(0,CEILING(((C57*7)-SUM((C59-SUM(C61:C64))*7*(1+$B$74),C64*7*$B$74))/(7*(1+$B$74)),1))

+ 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. Replies: 3
    Last Post: 01-10-2019, 09:34 AM
  2. Replies: 5
    Last Post: 02-16-2018, 06:50 AM
  3. Replies: 8
    Last Post: 09-22-2017, 05:41 AM
  4. Excel formula bar to display the result of the formula , not the formula?
    By max_max in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-18-2016, 07:15 PM
  5. Replies: 11
    Last Post: 06-06-2014, 03:34 PM
  6. how to hide formula in formula box, view lookup result in formula box?
    By vengatvj in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-14-2013, 04:06 PM

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