

Select the range you want to add comma after text.

This function needs to be put in the module in the worksheet or simply copy this to your personal.xlsb to access it from any of the sheet. Add comma at end of cell/text with Kutools for Excel 1. SInput = Replace$(sInput, Mid$(RemoveChars, i, 1), "") 'this will remove spaces The following vba code using a list marked as RemoveChars that are removed from the string under consideration.įunction removeSpecial(sInput As String) As String it only takes the value and converts it to number.Īpproach # 3 – Using VBA to remove characters: N() is another function present under math function section. The returned result is text hence we multiply it with 1 to get a numeric value.Īpproach # 2 – Extracting numeric value with N(): Where B1 is the cell in which we have the text and we want to eliminate comma “,”. The following formula works a treat when substituting for commas Text is the Text we want to remove the commas from, old text is the text we want to remove for our case this is comma, instance_num is optional, if you specify, the specific instance will be removed, and otherwise all the instances will be removed.
#INSERT COMMA EXCEL FORMULA HOW TO#
In this short tutorial, will show you how to make such numbers actually work like numbers!Ĭonsider a Number like this one: 12,645,990Īpproach # 1 – Substituting commas with a Formula:Įxcel has a built in function called SUBSTITUTE() that we use to substitute values in a text. The problem starts with the indication that numbers starts aligning to the left like text and they either have extra spaces or have imprint able characters that do not appear clearly but make numbers behave in an unusual manner. We encounter this problem of numbers behaving as text with commas when we import data from some other software in to excel sheet.
