ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   I said "Keep this text! Not a date!" (https://www.excelbanter.com/excel-programming/365553-re-i-said-keep-text-not-date.html)

pikapika13[_10_]

I said "Keep this text! Not a date!"
 

I have a column formatted as text. I have data that looks like this: "
through 5" or "2 through 14". My macro does a find and replace:

Range("D2:D100").Replace _
What:=" through ", Replacement:="-"

My result is not what I want; it gives me dates. Desired outputs ar
"1-5" or "2-14".

What do I need to do to accomplish this

--
pikapika1
-----------------------------------------------------------------------
pikapika13's Profile: http://www.excelforum.com/member.php...fo&userid=1089
View this thread: http://www.excelforum.com/showthread.php?threadid=55617



All times are GMT +1. The time now is 11:56 AM.

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