Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Concatenate an Hyphen
Hi Folks - I have account numbers that look like this:
10000000-03108-111-20-2102-52207-1200 10000001-03109-111-10-0000-52207-1200 10000002-03109-111-10-1600-52207-1200 etc.... What's the easist way to insert an hyphen after the first 2 digits so things look like this: 10-000000-03108-111-20-2102-52207-1200 10-000001-03109-111-10-0000-52207-1200 10-000002-03109-111-10-1600-52207-1200 Thanks, Michael |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Concatenate an Hyphen
=LEFT(A1,2) & "-" & RIGHT(A1,LEN(A1)-2)
-- Gary''s Student - gsnu200828 "Michael" wrote: Hi Folks - I have account numbers that look like this: 10000000-03108-111-20-2102-52207-1200 10000001-03109-111-10-0000-52207-1200 10000002-03109-111-10-1600-52207-1200 etc.... What's the easist way to insert an hyphen after the first 2 digits so things look like this: 10-000000-03108-111-20-2102-52207-1200 10-000001-03109-111-10-0000-52207-1200 10-000002-03109-111-10-1600-52207-1200 Thanks, Michael |
#3
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Concatenate an Hyphen
Michael wrote:
Hi Folks - I have account numbers that look like this: 10000000-03108-111-20-2102-52207-1200 10000001-03109-111-10-0000-52207-1200 10000002-03109-111-10-1600-52207-1200 etc.... What's the easist way to insert an hyphen after the first 2 digits so things look like this: 10-000000-03108-111-20-2102-52207-1200 10-000001-03109-111-10-0000-52207-1200 10-000002-03109-111-10-1600-52207-1200 Thanks, Michael =LEFT(A1,2)&"-"&MID(A1,3,9999) |
#4
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Concatenate an Hyphen
Awesome guys ... Thanks.
Michael "Glenn" wrote in message ... Michael wrote: Hi Folks - I have account numbers that look like this: 10000000-03108-111-20-2102-52207-1200 10000001-03109-111-10-0000-52207-1200 10000002-03109-111-10-1600-52207-1200 etc.... What's the easist way to insert an hyphen after the first 2 digits so things look like this: 10-000000-03108-111-20-2102-52207-1200 10-000001-03109-111-10-0000-52207-1200 10-000002-03109-111-10-1600-52207-1200 Thanks, Michael =LEFT(A1,2)&"-"&MID(A1,3,9999) |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Trying to use IF statement with hyphen | Excel Worksheet Functions | |||
Optional hyphen? | Excel Discussion (Misc queries) | |||
Copy Text to Right of Hyphen | Excel Discussion (Misc queries) | |||
...I want to display a hyphen instead of zero... | Excel Worksheet Functions | |||
Can I enter a date without using the / or hyphen? | Excel Discussion (Misc queries) |