Excel Formula: Remove extension from file name
Here is a list of file names including the extensions, how can you remove the extensions from the file names as below screenshot shown. In this tutorial, it provides a formula to deal with this job, and explains the arguments of the formula and how the formula works in Excel.
|Filename: the text string you want to remove the extension from.|
The formula returns the cell contents without extension.
How this formula work
Example: To remove the extension from file names in column B3:B5, please use below formula in C3:C5.
Press Enter keys to get the result in C3, then drag fill handle down to C5.
FIND(".",B3): the FIND function returns the position of a specific character. Here this formula gets the position of character “.”.
=LEFT(B3,FIND(".",B3)-1): the LEFT function extracts text from left side of a text string. Here this formula calculation steps will be shown as below:
Which returns five characters in left side of the text string in cell B3.
If there are two or more file names with extensions in a cell, this formula only returns the first file name. See screenshot:
- Find most requenst text with criteria
In some cases, you may want to find the text which appears most frequently based on a criterion in Excel. This tutorial introduces an array formula to handle this job and gives the explanation about the arguments of this formula.
- Combine cells with commas
Here this tutorial provides some formulas to join multiple cells into one cell with comma as separator as below screenshot shown, and also explains how the formulas work in Excel.
- Make text same length
If there is a list of texts with different lengths, for looking nicer, you can make these text with same length by adding trailing characters as below screenshot shown. Here it provides a formula which combines the LEN and REPT functions to handle it in Excel.
- Check if cell contains number
Sometimes, you may want to check if a cell contains numeric characters. This tutorial provides a formula which will return TRUE if the cell contains number, FALSE if cell does not contain number.