Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
I would like to add the string "1212" (no quotes) to some part numbers.
Essentially, I have two versions of part numbers to modify: xxxxxxx(space)(space)xxxxxxxxxx(space)xxxxx(space) xxxx or xxxxxxxxxx(space)xxxxx(space)(space)xxxxxxx(space) xxxx(space)xxxx The length of the xxxxxx strings varies and represents alphanumeric characters that must remain unchanged. The string "1212" (no quotes) must always be appended to the first xxxxx string of alphanumeric characters. Thus the end result of the modification should be as follows: xxxxxxx1212(space)(space)xxxxxxxxxx(space)xxxxx(sp ace)xxxx or xxxxxxxxxx1212(space)xxxxx(space)(space)xxxxxxx(sp ace)xxxx(space)xxxx All the part numbers that I want to modify will be listed in Column A of my spreadsheet. (There are other part numbers in other columns but I do not want to modify them.) Would somebody please suggest how to do it? This is beyond my knowledge of Excel. Thanks in advance. ---- Tiziano |
#2
![]() |
|||
|
|||
![]()
Tiziano,
=LEFT(A2,FIND(" ",A2)-1)& "1212" &MID(A2,FIND(" ",A2),999) Put this in another column, and copy down with the Fill Handle. Paste-Special-Values over the original for a permanent change. -- Earl Kiosterud mvpearl omitthisword at verizon period net ------------------------------------------- "Tiziano" wrote in message ... I would like to add the string "1212" (no quotes) to some part numbers. Essentially, I have two versions of part numbers to modify: xxxxxxx(space)(space)xxxxxxxxxx(space)xxxxx(space) xxxx or xxxxxxxxxx(space)xxxxx(space)(space)xxxxxxx(space) xxxx(space)xxxx The length of the xxxxxx strings varies and represents alphanumeric characters that must remain unchanged. The string "1212" (no quotes) must always be appended to the first xxxxx string of alphanumeric characters. Thus the end result of the modification should be as follows: xxxxxxx1212(space)(space)xxxxxxxxxx(space)xxxxx(sp ace)xxxx or xxxxxxxxxx1212(space)xxxxx(space)(space)xxxxxxx(sp ace)xxxx(space)xxxx All the part numbers that I want to modify will be listed in Column A of my spreadsheet. (There are other part numbers in other columns but I do not want to modify them.) Would somebody please suggest how to do it? This is beyond my knowledge of Excel. Thanks in advance. ---- Tiziano |
#4
![]() |
|||
|
|||
![]()
You're right, Don, it works just right.
I guess I am not much used to running macros... Thanks. ---- Tiziano "Don Guillett" wrote in message ... I just re-tested this. Why doesn't it work for you? Sub addnuminstr() For Each c In Selection X = InStr(c, " ") - 1 MsgBox Left(c, X) & 1212 & Right(c, Len(c) - X) Next c End Sub -- Don Guillett SalesAid Software "Tiziano" wrote in message ... I would like to add the string "1212" (no quotes) to some part numbers. Essentially, I have two versions of part numbers to modify: xxxxxxx(space)(space)xxxxxxxxxx(space)xxxxx(space) xxxx or xxxxxxxxxx(space)xxxxx(space)(space)xxxxxxx(space) xxxx(space)xxxx The length of the xxxxxx strings varies and represents alphanumeric characters that must remain unchanged. The string "1212" (no quotes) must always be appended to the first xxxxx string of alphanumeric characters. Thus the end result of the modification should be as follows: xxxxxxx1212(space)(space)xxxxxxxxxx(space)xxxxx(sp ace)xxxx or xxxxxxxxxx1212(space)xxxxx(space)(space)xxxxxxx(sp ace)xxxx(space)xxxx All the part numbers that I want to modify will be listed in Column A of my spreadsheet. (There are other part numbers in other columns but I do not want to modify them.) Would somebody please suggest how to do it? This is beyond my knowledge of Excel. Thanks in advance. ---- Tiziano |
#5
![]() |
|||
|
|||
![]()
Thanks, Earl!
It works just fine. ---- Tiziano "Earl Kiosterud" wrote in message ... Tiziano, =LEFT(A2,FIND(" ",A2)-1)& "1212" &MID(A2,FIND(" ",A2),999) Put this in another column, and copy down with the Fill Handle. Paste-Special-Values over the original for a permanent change. -- Earl Kiosterud mvpearl omitthisword at verizon period net ------------------------------------------- "Tiziano" wrote in message ... I would like to add the string "1212" (no quotes) to some part numbers. Essentially, I have two versions of part numbers to modify: xxxxxxx(space)(space)xxxxxxxxxx(space)xxxxx(space) xxxx or xxxxxxxxxx(space)xxxxx(space)(space)xxxxxxx(space) xxxx(space)xxxx The length of the xxxxxx strings varies and represents alphanumeric characters that must remain unchanged. The string "1212" (no quotes) must always be appended to the first xxxxx string of alphanumeric characters. Thus the end result of the modification should be as follows: xxxxxxx1212(space)(space)xxxxxxxxxx(space)xxxxx(sp ace)xxxx or xxxxxxxxxx1212(space)xxxxx(space)(space)xxxxxxx(sp ace)xxxx(space)xxxx All the part numbers that I want to modify will be listed in Column A of my spreadsheet. (There are other part numbers in other columns but I do not want to modify them.) Would somebody please suggest how to do it? This is beyond my knowledge of Excel. Thanks in advance. ---- Tiziano |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Modification of Part Numbers | Excel Discussion (Misc queries) | |||
Part Number/Qty Consolidations | Excel Discussion (Misc queries) | |||
need check two worksheets to lookup a value | Excel Discussion (Misc queries) | |||
Defining a number in a cell by text then subtracting it by the tex | Excel Worksheet Functions | |||
GET.CELL | Excel Worksheet Functions |