![]() |
|
#1
|
|||
|
|||
![]() Hi Guys, This is probably the easiest fix in the world but I can't seem to find a good solution to this at the moment; The issue I am having is that I need to create a database based on a scanned serial numbers, but only need certain information from these barcodes. An example of the kind of thing I am looking at; Barcode: 41BLSTHOMAS9991987 From this Barcode i want to copy and paste the characters THOMAS and 1987 into Column B & C of that row. The barcode always has the same amount of characters and the characters are always in the same place (ie dates of birth will always be 4 characters long and will alway be the 15-18th characters). Does anyone know any simple excel formula or VBA code that code do the above by any chance? Thanks! |
#2
|
||||
|
||||
![]()
Hi
perhaps Data - Text to columns - Fixed width and set delimiters as needed
__________________
Using O365 v2503 - Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post |
#3
|
|||
|
|||
![]()
Thanks Pecoflyer, that works in a way but it makes it a bit awkward.
Is there any way to select a certain group of characters in a cell without splitting it up, in Vba it seems to know where these characters are but selecting a specified group doesn't seem to be an option. |
#4
|
||||
|
||||
![]()
Assuming the 999 after THOMAS is just padding (i.e. longer names would have fewer 9s; shorter names, more), you could use formulae such as:
=SUBSTITUTE(MID(A1,6,9),9,"") =RIGHT(A1,4)
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
Soenke | Word VBA | 4 | 09-01-2016 08:55 AM |
![]() |
rsrasc | Excel Programming | 3 | 02-29-2016 10:53 PM |
![]() |
BIMwit | Word Tables | 1 | 05-14-2015 09:50 PM |
Copying text range of cells to different cells adds an extra line | jpb103 | Word VBA | 2 | 07-23-2014 12:22 PM |
Macro to Insert Text Into Cells Having Multiple Lines | revans611 | Excel Programming | 4 | 10-24-2011 10:15 AM |