How To Use Excel TRIM Function –Complete Guide

There is always a possibility of extra spaces being added to the text by mistake, which needs to be taken care of before performing any operations on the data.

Excel’s TRIM function can be used to achieve the same…!!!

1. What is the Excel TRIM Function?
2. What is the Syntax?
3. How to use it with an example?

1. What is the EXCEL TRIM Function?

The TRIM function can be used to take off the extra spaces between the words and any space characters at the start and end of the text.


2. What is the Syntax?

=TRIM(text)

  • text  = (Required) Text from which we want to remove the extra spaces.

Note :

  • Only ASCII space character (32 value) will be trimmed using TRIM.
  • Nonbreaking space character (160 value) commonly used in HTML entity will be ignored by TRIM(Instead use Substitute to replace all Nonbreaking space character with ASCII space character and then use TRIM)

3. How to use it with an example?

Assuming we have a data set pulled from a website which may contain some extra spaces in it, let us see how to clean it.

Excel TRIM Function.PNG

**Explained**

=TRIM(A3)
  • A3 = Reference to the cell ,from which we want to take off the extra spaces.

 

Hope it has helped you… 

Advertisements

Author: Sharath Raju

Founder@www.ExcelCult.com

Leave a Reply