Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
TEXT
I have large number of coding data like this (K4115KBA02WB005) these are 15
digits, what i want is to enter - sign after 10 digit (like K4115KBA02-WB005). please tell me some short way. -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...excel/200707/1 |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
TEXT
On Jul 10, 9:12 am, "adeel via OfficeKB.com" <u32736@uwe wrote:
I have large number of coding data like this (K4115KBA02WB005) these are 15 digits, what i want is to enter - sign after 10 digit (like K4115KBA02-WB005). please tell me some short way. -- Message posted via OfficeKB.comhttp://www.officekb.com/Uwe/Forums.aspx/ms-excel/200707/1 left(a1,10)&"-"&right(a1,5) should be close. just substitute your cell for a1. |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
TEXT
Use a helper column. If your data is in column A (beginning at A1), then in
another column (Z1 for example) enter the following formula and copy down as needed. HTH, Paul "adeel via OfficeKB.com" <u32736@uwe wrote in message news:74f6e21805dec@uwe... I have large number of coding data like this (K4115KBA02WB005) these are 15 digits, what i want is to enter - sign after 10 digit (like K4115KBA02-WB005). please tell me some short way. -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...excel/200707/1 |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
TEXT
If the number of characters should not always be 15, then this code might
work to add the hyphen after the 10th character if one exists. Sub addHyphen() 'Select Range manually, then run macro to add hyphen after 'the 10th character if it exists. Dim cell As Range For Each cell In Selection If Len(cell.Value) 10 Then cell.Value = Left(cell.Value, 10) & "-" & Mid(cell.Value, 11, 99) Else: cell.Value = "'" & cell.Value End If Next cell End Sub Vaya con Dios, Chuck, CABGx3 "adeel via OfficeKB.com" wrote: I have large number of coding data like this (K4115KBA02WB005) these are 15 digits, what i want is to enter - sign after 10 digit (like K4115KBA02-WB005). please tell me some short way. -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...excel/200707/1 |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
TEXT
It might have helped if I included the formula.
=LEFT(A1,20)&"-" & RIGHT(A1,LEN(A1)-10) Regards, Paul "PCLIVE" wrote in message ... Use a helper column. If your data is in column A (beginning at A1), then in another column (Z1 for example) enter the following formula and copy down as needed. HTH, Paul "adeel via OfficeKB.com" <u32736@uwe wrote in message news:74f6e21805dec@uwe... I have large number of coding data like this (K4115KBA02WB005) these are 15 digits, what i want is to enter - sign after 10 digit (like K4115KBA02-WB005). please tell me some short way. -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...excel/200707/1 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Text does not display in "Text boxs" and when wrapping text in a c | Excel Discussion (Misc queries) | |||
Text not continuing to wrap for large block of text in Excel cell | Charts and Charting in Excel | |||
merged cells into one text cell, size varies dependant on text dat | Excel Discussion (Misc queries) | |||
want to remove all text characters equal to one character in length from text string | Excel Worksheet Functions | |||
want to remove all text characters equal to one character in length from text string | Excel Worksheet Functions |