+ Reply to Thread
Results 1 to 9 of 9

Please help with if!

  1. #1
    Registered User
    Join Date
    12-15-2011
    Location
    boston, ma
    MS-Off Ver
    Excel 2003
    Posts
    18

    Please help with if!

    if anyone can help me I would greatly appreciate it. Im making a payroll calculator on my excel to check my work's calculation because they always seem a little off. I cant figure out this one cell' if function. ill try to explain it the best i can with my versian of the spreadsheet here


    n=any number

    b1=n
    b2=n

    b4= needs to be "(if (b1<40, keep it b1 but if b1>40, keep it 40)+(if"b2<40, keep it b2, but if b2>40, keep it 40)

    basically i need b4 to add the two up using the real numbers if theyre less than 40 or using only 40 is its greater than 40 for each cell.

    anyone? thank you so much.

  2. #2
    Forum Expert
    Join Date
    12-15-2009
    Location
    Chicago, IL
    MS-Off Ver
    Microsoft Office 365
    Posts
    3,177

    Re: Please help with if!

    Try this.

    =IF(B1<40,B1,IF(B1>40,40,""))+IF(B2<40,B2,IF(B2>40,40,""))

    PS: What happen if B1 or B2 = 40?

  3. #3
    Registered User
    Join Date
    12-15-2011
    Location
    Tiverton, Devon
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Please help with if!

    Hi

    Try:

    =IF(B1<40,B1,40)+IF(B2<40,B2,40)

    Does that make sense?

  4. #4
    Registered User
    Join Date
    12-15-2011
    Location
    boston, ma
    MS-Off Ver
    Excel 2003
    Posts
    18

    Re: Please help with if!

    Ill try both when i get home. If b1 and/or b2 =40 then it should use the 40

  5. #5
    Registered User
    Join Date
    12-15-2011
    Location
    boston, ma
    MS-Off Ver
    Excel 2003
    Posts
    18

    Re: Please help with if!

    JieJenn, thank you so much! it helped perfectly! i really do appreciate it. ive been trying to figure that out all day.

  6. #6
    Registered User
    Join Date
    12-15-2011
    Location
    boston, ma
    MS-Off Ver
    Excel 2003
    Posts
    18

    Re: Please help with if!

    AAHHHHH...one more thing. JieJenn, your formula worked for it the numbers were above and below 40, but if the numbers are 40 for both cells, the c4=True and i need it to enter a number.

  7. #7
    Registered User
    Join Date
    12-15-2011
    Location
    boston, ma
    MS-Off Ver
    Excel 2003
    Posts
    18

    Re: Please help with if!

    Actually, Woozer, yours worked perfectly. thank you!

  8. #8
    Forum Expert tigeravatar's Avatar
    Join Date
    03-25-2011
    Location
    Colorado, USA
    MS-Off Ver
    Excel 2003 - 2013
    Posts
    5,361

    Re: Please help with if!

    Alternate formula:
    =MIN(B1,40)+MIN(B2,40)
    Hope that helps,
    ~tigeravatar

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  9. #9
    Registered User
    Join Date
    12-15-2011
    Location
    boston, ma
    MS-Off Ver
    Excel 2003
    Posts
    18

    Re: Please help with if!

    Solved thanks everyone!

+ 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