+ Reply to Thread
Results 1 to 7 of 7

Formula to Substitute/Replace Text

  1. #1
    Forum Contributor
    Join Date
    02-08-2005
    MS-Off Ver
    Microsoft 365
    Posts
    810

    Formula to Substitute/Replace Text

    Hi,

    I have a column containing text lables in the form:

    Country A: Apples
    Country B: Oranges

    Can someone please suggest a formula that will simplify the above to:

    Apples
    Oranges

    I guess that a function like SUBSTITUTE might work but I'm not sure how to deal with the different countries, represented by A and B in my example.

    Thanks!
    Last edited by andrewc; 04-21-2020 at 09:58 AM.

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2403 Win 11 Home 64 Bit
    Posts
    23,810

    Re: Formula to Substitute/Replace Text

    Welcome to the forum

    Please attach a sample workbook (not a picture or pasted copy). Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Contributor
    Join Date
    02-08-2005
    MS-Off Ver
    Microsoft 365
    Posts
    810

    Re: Formula to Substitute/Replace Text

    Hi,

    Thanks for the advice

    I've added a workbook with sample data.

    Column A contains the original data while column B shows what I'd like to achieve with a formula.

    Thanks!
    Attached Files Attached Files

  4. #4
    Forum Guru Bo_Ry's Avatar
    Join Date
    09-10-2018
    Location
    Thailand
    MS-Off Ver
    MS 365
    Posts
    7,211

    Re: Formula to Substitute/Replace Text

    Please try
    =MID(A2,FIND(":",A2)+2,20)

  5. #5
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2403 Win 11 Home 64 Bit
    Posts
    23,810

    Re: Formula to Substitute/Replace Text

    On the Data Tab, Text to Columns. Delimeter = ":" (without quotes). Then delete column A.

  6. #6
    Forum Guru
    Join Date
    02-27-2016
    Location
    Vietnam
    MS-Off Ver
    2016
    Posts
    5,891

    Re: Formula to Substitute/Replace Text

    Or try:

    =REPLACE(A2,1,FIND(":",A2)+1,"")

  7. #7
    Forum Contributor
    Join Date
    02-08-2005
    MS-Off Ver
    Microsoft 365
    Posts
    810

    Re: Formula to Substitute/Replace Text

    Thank you!

+ 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. Find and Replace Text with SUBSTITUTE formula
    By creases in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 02-12-2020, 03:59 AM
  2. Replace/substitute after this formula
    By bweil in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 12-06-2019, 01:15 PM
  3. [SOLVED] Need help with simple REPLACE / SUBSTITUTE formula for 2 pivot tables
    By Megs35 in forum Excel Formulas & Functions
    Replies: 33
    Last Post: 10-24-2017, 12:24 AM
  4. Add text at the end of cell when using the SUBSTITUTE formula
    By tm-tom in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-13-2016, 08:51 AM
  5. [SOLVED] Substitute formula - i want to replace cell containing special characters "??????*"
    By karthikskengeri in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-14-2013, 06:21 AM
  6. How to use a substitute formula to substitute text entries to a different text entry
    By andybocchi in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 11-01-2010, 07:50 PM
  7. Replace or substitute formula maybe? Not sure what one to use?
    By essexpoker in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-24-2008, 11:25 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