cebu1014
asked on
Text function for trailing spaces
If I have a cell that contains something less than 12 characters , how can I get spaces added on end where total length is 12 characters in field?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
I see what you did there! :)
cebu1014,
Please note that my formula might mishandle entries that are already >12 characters long. For example, if the original entry is 17 characters long, my formula will truncate at the 12th character, while Shanan212's formula will return all 17 characters (and not add any trailing spaces).
Only you know whether or not there would ever be any initial data with >12 characters, and what should happen in that event.
:)
Patrick
Please note that my formula might mishandle entries that are already >12 characters long. For example, if the original entry is 17 characters long, my formula will truncate at the 12th character, while Shanan212's formula will return all 17 characters (and not add any trailing spaces).
Only you know whether or not there would ever be any initial data with >12 characters, and what should happen in that event.
:)
Patrick
ASKER
It will be 12 characters max. Never longer.