+ Reply to Thread
Results 1 to 7 of 7

Assign the alphabets

  1. #1
    Registered User
    Join Date
    06-13-2010
    Location
    kedah, malaysia
    MS-Off Ver
    Excel 2003
    Posts
    16

    Assign the alphabets

    Dear Friends,

    Now I'ave a new problem and it is as same as my previous one (adding the numbers only). But this time I'm going to calculate all of them. Before that,, here is the code:

    A = 1, B = 2, C = 3, D = 4, E = 5, F = 6. (nothing else, untill F only)

    3 3 B 1 = 3+3+B(2)+1 = 9

    4 0 C A = 4+0+C(3)+A(1) = 8

    How am I going to assign the A,B,C,D,E and F to the numbers I want to add. I'm not expert in excell, so please help me. Thank you.
    Last edited by royst; 07-04-2010 at 10:25 PM.

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Assign the alphabets

    A link to the previous question would be helpful
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,887

    Re: Assign the alphabets

    Hi Royst,

    Without using a macro or user-defined function, you might try the following array formula (confirmed with CTRL+SHIFT+ENTER, not just ENTER):

    =SUM(MID(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(A1,"A",1),"B",2),"C",3),"D",4),"E",5),"F",6),ROW(INDIRECT("1:"&LEN(A1))),1)+0)

  4. #4
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Assign the alphabets

    Non array assuming you will only ever enter numbers or A,B,C,D,E,F
    =sum(if(isnumber(a1),a1,code(upper(a1))-64),if(isnumber(b1),b1,code(upper(b1))-64),if(isnumber(c1),c1,code(upper(c1))-64),if(isnumber(d1),d1,code(upper(d1))-64))
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  5. #5
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Assign the alphabets

    It would seem from the prior post that the values are in separate cells

    =SUM(A1:A4,COUNTIF(A1:A4,{"A","B","C","D","E","F"})*{1,2,3,4,5,6})

  6. #6
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Assign the alphabets

    interesting use of countif

  7. #7
    Registered User
    Join Date
    06-13-2010
    Location
    kedah, malaysia
    MS-Off Ver
    Excel 2003
    Posts
    16

    Re: Assign the alphabets

    Dear Friends,

    My problems have solved and I'm closing my topics on "Sum of Integers", "Differentiate the Alphabets", "Adding the Numbers" and "Assign the Alphabets". All this thread's are related and the answers are found. I wish to thank's everyone, who involved in helping it. Mr. Pike, Mr.Zbor, Mr. Daddylonglegs, Mr. ChemistB, Mr. Excelkeechak, Mr. RoyUK, Mr. Paul, Mr. Martindwilson and Mr. DonkeyOte......
    YOU GUYS ARE WONDERFUL and THANK YOU.. THANK YOU very much.
    If I forget to mention anyone please forgive me. And I hope all of well and god's blessing always to you guys. I hope everyone could see this quote. THANK YOU n BYE.
    Last edited by shg; 07-05-2010 at 01:10 AM. Reason: deleted spurious quote

+ 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