+ Reply to Thread
Results 1 to 9 of 9

how to have a cell contain 3 diffrent formulas

  1. #1
    Registered User
    Join Date
    06-01-2015
    Location
    Cardiff
    MS-Off Ver
    2013
    Posts
    4

    how to have a cell contain 3 diffrent formulas

    Hi,

    is there a way a cell can contain 3 different formulas and then preform one of the formulas on the value of a different cell?

    so if cell a1 contains the word "high" then this formula is preformed in b1. if cell a1 contains "medium" then this formula is preformed and if cell a1 contains "low" then this formula is preformed.

    high - =IF(COUNTA(J2:N2)=0,I2+30,(MAX(J2:N2)+30))
    medium - =IF(COUNTA(J2:N2)=0,I2+90,(MAX(J2:N2)+90))
    low - =IF(COUNTA(J2:N2)=0,I2+120,(MAX(J2:N2)+120))

    i just wanted to know if i can combine all three formulas so if the word changes in cell A1 then the correct formula would be used in B1

    sorry if this makes no sense and any help would be 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 2406
    Posts
    44,298

    Re: how to have a cell contain 3 diffrent formulas

    Paste this into B1...

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    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
    Forum Expert daffodil11's Avatar
    Join Date
    07-11-2013
    Location
    Phoenixville, PA
    MS-Off Ver
    MS Office 2016
    Posts
    4,465

    Re: how to have a cell contain 3 diffrent formulas

    Please Login or Register  to view this content.
    Make Mom proud: Add to my reputation if I helped out!

    Make the Moderators happy: Mark the Thread as Solved if your question was answered!

  4. #4
    Registered User
    Join Date
    08-20-2014
    Location
    CLT
    MS-Off Ver
    2010
    Posts
    61

    Re: how to have a cell contain 3 diffrent formulas

    jr,

    You may be needing a nested if statement if I am understanding correctly.

    Formula should be: =if(a1="high",IF(COUNTA(J2:N2)=0,I2+30,(MAX(J2:N2)+30)),if(a1="medium",IF(COUNTA(J2:N2)=0,I2+90,(MAX(J2:N2)+90)),IF(COUNTA(J2:N2)=0,I2+120,(MAX(J2:N2)+120)))

    This is untested but I feel this should work and what I would try if I were you.

  5. #5
    Registered User
    Join Date
    06-01-2015
    Location
    Cardiff
    MS-Off Ver
    2013
    Posts
    4

    Re: how to have a cell contain 3 diffrent formulas

    Thanks, massive help! all sorted

  6. #6
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: how to have a cell contain 3 diffrent formulas

    Perhaps.

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

    Or even this.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by Norie; 06-01-2015 at 01:38 PM.
    If posting code please use code tags, see here.

  7. #7
    Forum Guru samba_ravi's Avatar
    Join Date
    07-26-2011
    Location
    Hyderabad, India
    MS-Off Ver
    Excel 2021
    Posts
    8,915

    Re: how to have a cell contain 3 diffrent formulas

    =IF(OR(A1={"High","Medium","Low"}),IF(COUNTA(J2:N2)=0,I2,MAX(J2:N2))+VLOOKUP(A1,{"High",30;"Medium",90;"Low",120},2,0),"")
    try this
    Samba

    Say thanks to those who have helped you by clicking Add Reputation star.

  8. #8
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: how to have a cell contain 3 diffrent formulas

    Assuming A1 can only be 1 of the 3 values, low medium or high..

    Try
    =IF(COUNT(J2:N2),MAX(J2:N2),I2)+30*MATCH(A1,{"High","","Medium","Low"},0)

  9. #9
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: how to have a cell contain 3 diffrent formulas

    ...
    or perhaps

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

+ 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. Starting a timer/ticker when a diffrent cell changes
    By RR2105 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-09-2013, 05:45 PM
  2. [SOLVED] Formula to get cell value under 3 diffrent conditionds
    By Sushil.thakur in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 05-29-2013, 02:57 AM
  3. VLookup into diffrent worksheets in a diffrent workbook
    By joffy1979 in forum Excel Formulas & Functions
    Replies: 9
    Last Post: 05-26-2013, 11:35 AM
  4. Need to Pull 2 diffrent sets of characters from cell
    By Runamuck in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-11-2013, 07:03 PM
  5. how to Split Cell with no limitor only diffrent fonts
    By shijiazhuang in forum Excel General
    Replies: 3
    Last Post: 09-17-2010, 07:53 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