ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   can i write a macro to truncate alpha-numeric data? (https://www.excelbanter.com/excel-discussion-misc-queries/104627-can-i-write-macro-truncate-alpha-numeric-data.html)

T-Dot

can i write a macro to truncate alpha-numeric data?
 
I have imported a bunch of data into excel, however, the data I have has a
bunch of extra characters at the end that I don't need. Can I write a Macro
to delete a set number of characters off of each cell that I run the macro on?

raypayette

can i write a macro to truncate alpha-numeric data?
 

This is the key code:
a = Replace(ActiveCell.Value, "s", "")
the rest is up to you!


--
raypayette


------------------------------------------------------------------------
raypayette's Profile: http://www.excelforum.com/member.php...o&userid=29569
View this thread: http://www.excelforum.com/showthread...hreadid=570980


paul

can i write a macro to truncate alpha-numeric data?
 
you dont necessarily need a macro .Post a sample of what the dates look like
now what you want them to look like
--
paul

remove nospam for email addy!



"T-Dot" wrote:

I have imported a bunch of data into excel, however, the data I have has a
bunch of extra characters at the end that I don't need. Can I write a Macro
to delete a set number of characters off of each cell that I run the macro on?



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

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