Here's a truly efficient way to get rid of garbage characters that have tagged along with imported data: Just let the Excel CLEAN function remove them for you.
Excel includes a number of functions that allow you to remove printable characters, like spaces, from imported data. But what if your data contains nonprintable characters, like the ones shown in Figure A?
To clean up this data, Excel provides the CLEAN function. Follow these steps:
- Select C2:C10.
- Enter the following formula: =CLEAN(A2)
- Press Ctrl + Enter (Figure B).
Excel displays the contents of the cells without the nonprintable characters. You can now copy the results to another part of the workbook using the Paste Special option to copy the values without the formulas (Figure C).
Miss an Excel tip?
Check out the Microsoft Excel archive and catch up on other Excel tips.
Help users increase productivity by automatically signing up for TechRepublic's free Microsoft Office Suite newsletter, featuring Word, Excel, and Access tips, delivered each Wednesday.