Dim strValue As String strValue = "abc" 'the value from the userform If Len(strValue) > 35 Then strValue = Left(strValue, 35) Else Do Until Len(strValue) = 35 strValue = strValue & Chr(32) 'OR 'strValue = Chr(32) & strValue Loop End If