Title: Remove Trailing Spaces from Cells in Excel - Free Excel Tutorial
Headings: Remove Trailing Spaces from Cells in Excel
Remove Trailing Spaces from Cells in Excel
Remove Trailing Spaces from Cells with Formula
Remove Trailing Spaces from Cells with VBA Macro
Related Functions

Content: Just do the following steps: #1 select one range of cells that you want to remove trailing spaces
#2 open your excel workbook and then click on “ Visual Basic ” command under DEVELOPER Tab, or just press “ ALT+F11 ” shortcut. #3 then the “ Visual Basic Editor ” window will appear. #4 click “ Insert ” ->” Module ” to create a new module. #5 paste the below VBA code into the code window. Then clicking “ Save ” button. Sub RemovTrailSpaces ()  Dim cel As Range  For Each cel In Selection. Cells  cel = Trim (cel)  Next End Sub
#6 back to the current worksheet, then run the above excel macro. Click Run button. #7 Let’s see the result.