![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat6_zps2f9888ea.jpg)
Hmmm. Unlikely? No, I've been handed data apparently "managed" by 2 or more people, with different formatting within the same column. It does happen.
Let's set things right.
Clicking Ctrl + F on your keyboard brings up the Find and Replace dialog box. From there, click Format, then Format again.
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat1_zps60586a53.jpg)
Select Text from the Number tab, then click OK.
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat2_zpsfa1761c8.jpg)
Click Find All, then type Ctrl + A on your keyboard to select all cells found with Text format.
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat3_zps9db956f7.jpg)
Bring up the right-click menu with your mouse (or keyboard) and select Format Cells.
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat4_zps3afad3aa.jpg)
Now it's a matter of choosing a more suitable format. As it turns out, the other cells have been formatted as 00000 to show the numbers as 5 digits. To match this, I select Custom on the Number tab, then type in 00000 and click OK.
![](https://i1373.photobucket.com/albums/ag369/aengwirda/TextFormat5_zps9ffc2d8f.jpg)
Yay! Hang on... cell B1 still shows a total of 3. Yikes!
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat6_zps2f9888ea.jpg)
VBA is your friend. Make sure all cells are selected. Type Ctrl + F11 to show the Visual Basic Editor, then Ctrl + G to show the Immediate Window (if not already visible).
Now type
selection.value = selection.value
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat7_zps5fbb3c95.jpg)
Click Enter on your keyboard. Now all looks good.
![](https://i1373.photobucket.com/albums/ag369/aengwirda/Excel_Tips/Text%20Troubles/TextFormat8_zpse6a8ab9f.jpg)
Treat yourself to a well-earned cup of tea or coffee. (The alcohol beverages come after work)
See you next time.
Easy to understand flow
ReplyDeleteThank you for sharing. I run into this situation often. I will try this next time. Cheers!
ReplyDelete