Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Leslie
 
Posts: n/a
Default Find 1 word and replace it and leave the leading zero

I have a report with sub-totals in Excel 2003 and I have copied the
sub-totals as a paste special values to a new spread sheet and want to remove
the word total and keep a leading zero that is part of our Part Numbers. is
there an easy way to do that? Here's an example cell
Befo
03010042 Total
After I want this:
03010042
When I do a find and replace it removes the leading 0 even with the column
set as a text column.

  #2   Report Post  
Posted to microsoft.public.excel.misc
ewan7279
 
Posts: n/a
Default Find 1 word and replace it and leave the leading zero

Hi,

Format the cell after you have replaced the contents:

Format = Cells = Custom, then in the Type bar enter "00000000" (without
the quotation marks)

Ewan

"Leslie" wrote:

I have a report with sub-totals in Excel 2003 and I have copied the
sub-totals as a paste special values to a new spread sheet and want to remove
the word total and keep a leading zero that is part of our Part Numbers. is
there an easy way to do that? Here's an example cell
Befo
03010042 Total
After I want this:
03010042
When I do a find and replace it removes the leading 0 even with the column
set as a text column.

  #3   Report Post  
Posted to microsoft.public.excel.misc
Don Guillett
 
Posts: n/a
Default Find 1 word and replace it and leave the leading zero

format the selected area as TEXT first and then use.
Sub removetextleaveleadingzero()

For Each c In Selection
c.Value = Left(c, Len(c) - 5)
Next

End Sub

--
Don Guillett
SalesAid Software

"Leslie" wrote in message
...
I have a report with sub-totals in Excel 2003 and I have copied the
sub-totals as a paste special values to a new spread sheet and want to
remove
the word total and keep a leading zero that is part of our Part Numbers.
is
there an easy way to do that? Here's an example cell
Befo
03010042 Total
After I want this:
03010042
When I do a find and replace it removes the leading 0 even with the column
set as a text column.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
copy and pasting a find all list into another column Ben Excel Discussion (Misc queries) 18 December 31st 05 10:51 PM
How can I use find and replace to delete a word in Excel? callpaultwt Excel Discussion (Misc queries) 2 December 1st 05 09:11 PM


All times are GMT +1. The time now is 08:25 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"