View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Stefi Stefi is offline
external usenet poster
 
Posts: 2,646
Default Formatting string in groups of letters...

=LEFT(A2,LEN(A2)-15)&" "&MID(A2,LEN(A2)-14,5)&" "&MID(A2,LEN(A2)-9,5)&"
"&RIGHT(A2,5)

Regards,
Stefi

HBj ezt *rta:

Hi,

How can a string without spaces be formatted to display the string in groups
of five characters.
Example:

246 81357 99876 54321

Only the left-most group can contain less than 5 characters

--
Håkan