+ Reply to Thread
Results 1 to 12 of 12

Replace and Right Function for Job title

  1. #1
    Registered User
    Join Date
    11-03-2022
    Location
    USA
    MS-Off Ver
    365
    Posts
    7

    Replace and Right Function for Job title

    I want to know if I can combine the Replace and right function in the same cell below is what I am trying to achieve I want to keep the title but change the last 4 characters with a new number in a separate row.

    Current New Replacement number in separate row

    4100-025-12 - Bottle Washer (72) 87

    Desired outcome

    4100-025-12 - Bottle Washer (87)

    Thank you in advance I am sure it's easy, but I cannot come up with the correct sequence.

    HR_Dude

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,343

    Re: Replace and Right Function for Job title

    Welcome to the forum.

    Do ALL of your text strings follow EXACTLY this pattern? If not, please provide a workbook with a sample SET of data for us to work with.

    There is a typo in your forum profile: it's MS365, NOT 360.

    You could try this:

    =LEFT(A1,LEN(A1)-7)&"("&RIGHT(A1,2)&")"

    AliGW on MS365 Beta Channel (Windows 11) 64 bit

    A
    1
    4100-025-12 - Bottle Washer (72) 87
    2
    4100-025-12 - Bottle Washer (87)
    Sheet: Sheet1
    Last edited by AliGW; 11-03-2022 at 11:18 AM.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    11-03-2022
    Location
    USA
    MS-Off Ver
    365
    Posts
    7

    Re: Replace and Right Function for Job title

    Hi yes all of them follow the same sequence...I updated my profile :-)

    Thank you for your help see example file
    Attached Files Attached Files

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,343

    Re: Replace and Right Function for Job title

    In E2 copied down:

    =LEFT(C2,LEN(C2)-(LEN(C2)-FIND("(",C2)+1))&" ("&D2&")"

    Or, if you have the latest insider version:

    =TEXTBEFORE(C2,"(")&" ("&D2&")"
    Attached Files Attached Files

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,086

    Re: Replace and Right Function for Job title

    If you have TEXTBEFORE try:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  6. #6
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,086

    Re: Replace and Right Function for Job title

    All rows in one go:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    11-03-2022
    Location
    USA
    MS-Off Ver
    365
    Posts
    7

    Re: Replace and Right Function for Job title

    Its almost there but I need it to add the new number to the title in "D" (different for each one).

  8. #8
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,343

    Re: Replace and Right Function for Job title

    What is almost there? I gave you two options that do exactly what you want in post #4, and Trevor has offered another possibility.

  9. #9
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,086

    Re: Replace and Right Function for Job title

    I don't understand what you are looking for. I agree with Ali; if you have TEXTBEFORE, you have several options.
    Attached Files Attached Files

  10. #10
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,343

    Re: Replace and Right Function for Job title

    HR_DUDE - have you looked at the workbook I provided in post #4?

  11. #11
    Registered User
    Join Date
    11-03-2022
    Location
    USA
    MS-Off Ver
    365
    Posts
    7

    Re: Replace and Right Function for Job title

    AliGW - you are awesome just what I was looking for!

  12. #12
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    79,343

    Re: Replace and Right Function for Job title

    Look at Trevor's suggestion in post #6 - it's better if you have TEXTBEFORE.

    Glad to have helped.

    If that takes care of your original question, please choose Thread Tools from the menu link above and mark this thread as SOLVED.

    Also, if you have not already done so, you may not be aware that you can thank those who have helped you by clicking the small star icon (* Add Reputation) located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of all those who offered help.

+ 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. Loop through all charts and replace title
    By peter.yaacoub in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-11-2022, 11:49 AM
  2. [SOLVED] Use Replace Function to Replace Whole Word
    By exceere in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-05-2020, 09:03 PM
  3. REPLACE function help replace two separate texts Ctrl H
    By Uldis in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-23-2015, 10:51 AM
  4. [SOLVED] Need help with REPLACE function to replace HEX A0 with HEX 20 in string
    By flyboy54 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-26-2013, 12:52 PM
  5. Macro to find and replace the title link of open workbook
    By brad999 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-05-2013, 09:11 AM
  6. Replace Function:Replace" and type in
    By ronnyc in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 03-19-2007, 06:26 PM
  7. replace title
    By Terry in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 11-01-2005, 12:05 AM

Tags for this Thread

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