ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   automatically copy first 12 characters in one field to another? (https://www.excelbanter.com/excel-programming/347938-automatically-copy-first-12-characters-one-field-another.html)

JFletcher

automatically copy first 12 characters in one field to another?
 
I am trying to write a formula that will automatically copy just the first 12
characters of a field into another field. I'm trying to isolate some
information.

Wolf

automatically copy first 12 characters in one field to another?
 
if a1 contains your text, put this formula in e.g. in b2:
=left(a1,12)

Wolf

"JFletcher" wrote:

I am trying to write a formula that will automatically copy just the first 12
characters of a field into another field. I'm trying to isolate some
information.


STEVE BELL

automatically copy first 12 characters in one field to another?
 
You can use the worksheet function:
=Left(A1,12)
where A1 is the field you want...

You can also build this into code
Range("D1")=Left(Range("A1"),12)

The code leaves the result without the formula.

--
steveB

Remove "AYN" from email to respond
"JFletcher" wrote in message
...
I am trying to write a formula that will automatically copy just the first
12
characters of a field into another field. I'm trying to isolate some
information.





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

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