Formula for deleting text in cell

PuzzledK

New Member
Joined
Feb 11, 2022
Messages
4
Office Version
  1. 2010
Platform
  1. Windows
Hello. There must be a way to do this, but I'm not experienced in Excel, so would really appreciate any help.

I have to type up a list at my work, but the report prints it to the cell with last name and first name. How can I enter a formula that will delete the first name? I only want doe in that cell and delete the /john

1644632232689.png
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
Hi

Excel Formula:
=SUBSTITUTE(D1,"/john","")
Thank you for your answer, but I don't think that will work. Not all the names are john, just using that as an example. I think I have to do something with a great or less than 0 after the /
 
Upvote 0
Welcome to the MrExcel board!

If you actually want to delete the first names from that column then you can do them all at once
  1. Select the column by clicking its letter label
  2. Find/Replace (Ctrl+H or via the ribbon) with
    Find what: /*
    Replace with: leave blank
    Replace All
 
Upvote 0
If you didn't want to change the original data like that you could still do them all at once
  1. Select column D
  2. Data ribbon tab -> Text to Columns -> Delimited -> Next -> Clear all the delimiter boxes except 'Other' and put a forward slash in the box to the right of 'Other' -> Next -> Destination: E1 -> Click in the column at the bottom with the first names (it will go black) then select 'Do not import' above -> Finish
 
Upvote 0
Solution
Welcome to the MrExcel board!

If you actually want to delete the first names from that column then you can do them all at once
  1. Select the column by clicking its letter label
  2. Find/Replace (Ctrl+H or via the ribbon) with
    Find what: /*
    Replace with: leave blank
    Replace All
Worked like MAGIC! Thank you so much.
 
Upvote 0
If you didn't want to change the original data like that you could still do them all at once
  1. Select column D
  2. Data ribbon tab -> Text to Columns -> Delimited -> Next -> Clear all the delimiter boxes except 'Other' and put a forward slash in the box to the right of 'Other' -> Next -> Destination: E1 -> Click in the column at the bottom with the first names (it will go black) then select 'Do not import' above -> Finish
Thank you for your time Peter. I really appreciate it.
 
Upvote 0

Forum statistics

Threads
1,214,622
Messages
6,120,580
Members
448,972
Latest member
Shantanu2024

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top