ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   is there a way to delete all characters to the right of a ":"? (https://www.excelbanter.com/excel-discussion-misc-queries/154015-there-way-delete-all-characters-right.html)

[email protected]

is there a way to delete all characters to the right of a ":"?
 
XL 2003

the number of characters to the left of the ":" will vary

....Lisa


ExcelBanter AI

Answer: is there a way to delete all characters to the right of a ":"?
 
Yes, there is a way to delete all characters to the right of a ":" in Excel 2003. You can use the "Text to Columns" feature to split the text into separate columns based on the ":" delimiter and then delete the unwanted column.

Here are the steps to do this:
  1. Select the cell or range of cells that contain the text you want to split.
  2. Go to the "Data" tab in the Excel ribbon and click on "Text to Columns".
  3. In the "Convert Text to Columns Wizard" dialog box, choose "Delimited" and click "Next".
  4. Check the box next to "Other" and enter ":" in the box next to it. You should see a preview of how the text will be split.
  5. Click "Next" and choose the destination for the split data. You can choose to overwrite the original cells or specify a new range.
  6. Click "Finish" to split the text into separate columns.
  7. Now you can delete the unwanted column by selecting it and pressing the "Delete" key on your keyboard.

That's it! The text to the right of the ":" should now be deleted.

Dave O

is there a way to delete all characters to the right of a ":"?
 
Hi, Lisa-
This formula will do it:
=MID(A1,1,FIND(":",A1,1)-1)

Dave O


Rick Rothstein \(MVP - VB\)

is there a way to delete all characters to the right of a ":"?
 
XL 2003

the number of characters to the left of the ":" will vary


This will leave the colon and remove everything after it...

=LEFT(A20,FIND(":",A20))

This will remove the colon also...

=LEFT(A20,FIND(":",A20)-1)

Rick

[email protected]

is there a way to delete all characters to the right of a ":"?
 
On Aug 13, 4:17 pm, "Rick Rothstein \(MVP - VB\)"
wrote:
XL 2003


the number of characters to the left of the ":" will vary


This will leave the colon and remove everything after it...

=LEFT(A20,FIND(":",A20))

This will remove the colon also...

=LEFT(A20,FIND(":",A20)-1)

Rick


Thank you!!!

....Lisa



All times are GMT +1. The time now is 06:50 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com