+ Reply to Thread
Results 1 to 8 of 8

Combining 3 formulas into one

  1. #1
    Registered User
    Join Date
    04-26-2013
    Location
    Allover
    MS-Off Ver
    Excel 2007,2010
    Posts
    13

    Combining 3 formulas into one

    Hi there,

    I'm trying to combine the 3 formulas below that I currently have in column F of the attached spreadsheet so that they all evaluate at the same time.

    =VALUE(LEFT(C4,6))
    =VALUE(MID(C6,3,10))
    =VALUE(MID(C7,3,6))

    Any help would be greatly appreciated.

    Attachment 231528
    Last edited by clickclick; 04-27-2013 at 09:56 PM.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,814

    Re: Combining 3 formulas into one

    Put this formula in F2:

    =IF(ISNUMBER(C2),VALUE(LEFT(C2,6)),IF(OR(ISNUMBER(SEARCH("-",C2)),LEN(C2)<14),VALUE(MID(C2,3,10)),VALUE(MID(C2,3,6))))

    then copy down.

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    04-26-2013
    Location
    Allover
    MS-Off Ver
    Excel 2007,2010
    Posts
    13

    Re: Combining 3 formulas into one

    Awesome, thanks so much for your help!

  4. #4
    Valued Forum Contributor Lemice's Avatar
    Join Date
    04-13-2013
    Location
    Somewhere.
    MS-Off Ver
    Excel 2016
    Posts
    696

    Re: Combining 3 formulas into one

    Please disregard my following post. I'm glad that you've found a solution to your problem.

    Hello,

    Do you have any condition that indicate in which case take how many number (For example, on worksheet Bank, C7, you take out 6 numbers starting from the 3rd, but on other cases when there are letters, you take 10)

    By the way, this file looks awfully familiar ...
    (copy pasta from Ford)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools

    Regards,
    Lem

  5. #5
    Registered User
    Join Date
    04-26-2013
    Location
    Allover
    MS-Off Ver
    Excel 2007,2010
    Posts
    13

    Re: Combining 3 formulas into one

    oh right...I didn't even think of that. Thanks for pointing it out.

    DD9301795226-04-APR-13 if the text contains DD then =VALUE(MID(C6,3,10))
    CB164319100325110740 if the text contains CB then =VALUE(MID(C7,3,6))
    RD9300063626 if the text contains RD then =VALUE(MID(C9,3,10))
    otherwise - =VALUE(LEFT(C2,6))
    Last edited by clickclick; 04-27-2013 at 11:12 PM.

  6. #6
    Registered User
    Join Date
    04-26-2013
    Location
    Allover
    MS-Off Ver
    Excel 2007,2010
    Posts
    13

    Re: Combining 3 formulas into one

    i think that will work though right?

  7. #7
    Valued Forum Contributor Lemice's Avatar
    Join Date
    04-13-2013
    Location
    Somewhere.
    MS-Off Ver
    Excel 2016
    Posts
    696

    Re: Combining 3 formulas into one

    If so, this might be the formula you are looking for
    Please Login or Register  to view this content.
    Assuming the indicating texts (DD, RD and CB) can only be the first 2. Let me know if they can be anywhere among the numbers ...

  8. #8
    Registered User
    Join Date
    04-26-2013
    Location
    Allover
    MS-Off Ver
    Excel 2007,2010
    Posts
    13

    Re: Combining 3 formulas into one

    Perfect, thanks again for your help, i'm sure this won't be the last time you will here from me. :-)

+ 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