View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Teethless mama Teethless mama is offline
external usenet poster
 
Posts: 3,718
Default What excel snyntax and or function will add leading spaces

=A1&REPT(" ",7-LEN(A1))

"Sharon" wrote:

I have a requirement to have meet a specified field length. For example if
name field length is 7 and the name entered is SAM; what functions
(operations, marcos, vb scripts) are available in excel that can
automatically add either leading or trailing spaces to make the length equal
to 7?