Method 5 – Remove Spaces after Text Using the LEFT Function in Excel If we know how many spaces there are on the right of the text (i.e., after the text), we can remove the spaces using theLEFTfunction. We havethree spaceson the right of the text. Incell C5,insert the following:...
Subremove_space()Dimsearch_rangeAsRangeDimcellAsRange'Taking User Input'Application.DisplayAlerts=FalseOnErrorResumeNextSetsearch_range=Application.SelectionSetsearch_range=Application.InputBox("Please Enter Your Range of Cells","Data Range",Type:=8)OnErrorGoTo0Ifsearch_rangeIsNothingThenExitSubEndIf'Loo...
You can use all these methods on Excel and if you are not comfortable with using Excel, you can try a free alternative calledWPS Office. With WPS Office, you'll enjoy a plethora of features that are not available in Microsoft Office, it will be easier to find andremove space in excelbe...
There can be non-breaking spaces in a text as well. To remove them, simply use Substitute Function and replace the non-breaking space with a normal space.Lastly, if you wish to remove all spaces in Excel the Find & Replace feature would be your best match!
if you want to remove all the spaces associated with numbers or text, this method is the go-to. by using a simple formula, you can remove all the spaces from your data. this method works on the principle of replacing the space with an empty string. to trim the values of unwanted ...
Step 1:To remove these trailing spaces, click on an empty cell. Step 2:Enter the Trim Function in WPS Office by entering “=TRIM(“. This will initiate the Trim Function. Step 3:Next, we will need to select the cell with text that contains trailing spaces; cell “A2”. ...
PressSpace barin theFind Whatfield and make sure the "Replace with" field is empty. Click on the "Replace all" button, and then pressOk. Voila! All spaces are removed. Using formula to remove all spaces You may need to delete all blanks, like in a formula chain. To do this, you ca...
Remove trailing whitespace =TRIM(LEFT(A1, LEN(A1)-1))&""" Remove extra whitespace =TRIM(A2) If you want to remove all whitespaces, select the cell you use, press Ctrl + H to enable Find and Replace dialog, type a space in the Find what text box, and leave nothing in Replace with...
Also read:How to Remove Space before Text in Excel Method #2: Using TRIM, SUBSTITUTE, and CHAR Functions (Removing Non-breaking Leading Spaces) If you pull data from a website into Excel, it may come in with non-breaking leading spaces. ...
to do the job. The reason is that the TRIM function can only remove thespace character that has value 32 in the 7-bit ASCII system, whilea non-breaking space character has value 160 in the 7-bit ASCII. Therefore, how we canremove all extra spaces including non-breaking spacesin Excel?