+ Reply to Thread
Results 1 to 6 of 6

If a cell = text then total next column

  1. #1
    Forum Contributor
    Join Date
    11-11-2010
    Location
    England
    MS-Off Ver
    Excel 2019
    Posts
    202

    If a cell = text then total next column

    anyone help me with the following formula

    Basically a1 has the following, WO, WL, OT, S, WS, A, WO, WL
    and a2 has the following sums next to the above 2.5, 1.2, 3.4, 4.8, 7.7, 1.1, 2.5, 1.0

    i want to basically work out if a1 = WO or WL then give them the total sum.

    this would give us a result of WO & WL = 7.2

  2. #2
    Forum Expert
    Join Date
    02-19-2013
    Location
    India
    MS-Off Ver
    07/16
    Posts
    2,386

    Re: If a cell = text then total next column

    Hello m_789 can you please upload a sample book with how you want the result written manually and where you want the same.

  3. #3
    Forum Contributor
    Join Date
    11-11-2010
    Location
    England
    MS-Off Ver
    Excel 2019
    Posts
    202

    Re: If a cell = text then total next column

    no problem have added and highlighted in yellow what i want the results to be like
    Attached Files Attached Files

  4. #4
    Forum Expert Ace_XL's Avatar
    Join Date
    06-04-2012
    Location
    UAE
    MS-Off Ver
    2016
    Posts
    6,074

    Re: If a cell = text then total next column

    In F1
    =SUM(SUMIF($A$1:$A$10,{"WO","WL"},$B$1:$B$10))

    In F2
    =SUMIF($A$1:$A$10,"S",$B$1:$B$10)

    Change highlighted portion for varied results. Alternatively you can also cell reference the highlighted part
    Life's a spreadsheet, Excel!
    Say thanks, Click *

  5. #5
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: If a cell = text then total next column

    An easy way could be this if you want to use cell reference.

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  6. #6
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: If a cell = text then total next column

    Quote Originally Posted by m_789 View Post
    ....
    Basically a1 has the following, WO, WL, OT, S, WS, A, WO, WL
    and a2 has the following sums next to the above 2.5, 1.2, 3.4, 4.8, 7.7, 1.1, 2.5, 1.0

    i want to basically work out if a1 = WO or WL then give them the total sum.

    this would give us a result of WO & WL = 7.2
    Your sample differs greatly from the original question ...
    Please be more careful when describing your problems in future.

    For what it's worth this workbook does as you originally requested.
    Attached Files Attached Files
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

+ 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. [SOLVED] Create formula to sum column total if specific text is present in second column
    By Banir in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-08-2013, 07:48 AM
  2. Formula to calculate total from column with text
    By Sadalif in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 07-26-2013, 01:52 PM
  3. [SOLVED] Column total as a number total from column with text
    By birchetts in forum Excel General
    Replies: 16
    Last Post: 03-26-2012, 07:43 AM
  4. Total based on column text code
    By jwzumwalt in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-18-2011, 02:45 PM
  5. Add total number of rows (text) in a column
    By rostroncarlyle in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-15-2005, 02:30 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