+ Reply to Thread
Results 1 to 4 of 4

Multiple Substitutes

  1. #1
    Registered User
    Join Date
    04-05-2010
    Location
    uk
    MS-Off Ver
    Excel 2003 and beyond
    Posts
    4

    Multiple Substitutes

    Hi
    Hopefully this will be a simple one for you Guru's to solve as i'm getting too big of a headache trying to work it out.

    I'm trying to use the substitute function to get rid of more than one criteria.
    e.g. > or To

    As i'm not too experienced with other functions i don't know if there is another function that could do that for me?
    Hopefully my example wookbook shows what i would like to achieve.
    Many thanks for any comments.
    Attached Files Attached Files
    Last edited by JRowe; 04-08-2010 at 05:50 AM. Reason: solved

  2. #2
    Forum Expert
    Join Date
    10-10-2008
    Location
    Northeast Pennsylvania, USA
    MS-Off Ver
    Excel 2007
    Posts
    2,387

    Re: Multiple Substitutes

    JRowe,

    The formula in cell D1:
    =IF(ISERROR(INDIRECT((A1&B1&SUBSTITUTE(C1," to ","")))),"",INDIRECT((A1&B1&SUBSTITUTE(C1," to ",""))))



    The formula in cell D2:
    =IF(ISERROR(INDIRECT((A1&B1&SUBSTITUTE(C1,">","")))),"",INDIRECT((A1&B1&SUBSTITUTE(C1,">",""))))
    Have a great day,
    Stan

    Windows 10, Excel 2007, on a PC.

    If you are satisfied with the solution(s) provided, please mark your thread as Solved by clicking EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.

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

    Re: Multiple Substitutes

    If you're looking to return the cell contents via a single calculation perhaps:

    =INDIRECT(A1&B1&SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(C1," to ",""),">","")," ",""))

  4. #4
    Registered User
    Join Date
    04-05-2010
    Location
    uk
    MS-Off Ver
    Excel 2003 and beyond
    Posts
    4

    Re: Multiple Substitutes

    Stan
    Thank You for your reply, but not quite what i was looking for.

    DonkeyOte
    Thank You for your reply, that worked perfectly.
    Now gotta work out how to intergrate that into my more complicated worksheet haha
    Thanks for all your comments.

+ 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