Convert a column value to a number

Posted on 2012-08-15
Last Modified: 2012-08-15

I have a spreadsheet with a column that contains either A, B or C (or blank).

I want to make a sum in the bottom of the column that awards 3 for an A, 2 for a B and 1 for a C, 0 for blank...

Is that possible?

Question by:prosit
    LVL 26

    Accepted Solution

    Hi, funch.

    Assuming that the cells you're interested in are A1:A10...
    =3*COUNTIF(A1:A10,"A")+ 2*COUNTIF(A1:A10,"B")+COUNTIF(A1:A10,"C")

    LVL 2

    Author Comment

    problem is that they are not...

    they are a spreadsheet with hidden rows, so it would be row 56, 75,90 etc. on one, but different on another...

    any ideas on that... worst case scenario I can delete the rows, it's not the end of the world...

    LVL 2

    Author Closing Comment

    Actually it worked, I just added the max number of rows and it worked...

    tnx a bunch
    LVL 26

    Expert Comment

    Thanks, funch.

    As you've discovered, the formula doesn't care whether the rows are hidden or not. That's fine - unless you want to exclude A/B/C values in the hidden rows.

    Featured Post

    What Is Threat Intelligence?

    Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

    Join & Write a Comment

    MS Access 2003 or later To MySQL Migration Project Hello All, this is my second article in the category of MS-OFFICE Automation. In internet I am not able to find any comprehensive resource on the Migration of MS Access back-end to MySQL so I fin…
    User Beware!  This is a rather permanent solution to removing your email from an exchange server.  The only way to truly go back is to have your exchange administrator restore your mailbox from backups.  This is usually the option of last resort.  A…
    Viewers will learn the basics of slicers and timelines for both PivotTables and standard Excel tables in Excel 2013.
    This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.

    730 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now