I really tried a LOT with in-built functions and also with google search but none of the ways doesn't worked out for expected result.
My exact problem is: I've few numeric columns which i got from a website and copied directly into excel.
In those columns there is a SINGLE Leading space at the beginning of each number in the cell of the entire column. Example 523946.00
. In this number there is a single space before the digit 5
.
I tried a lot with TRIM and SUBSTITUTE in-built functions but nothing able to resolve my problem of removing spaces.
And also my expectation is when i select two or multiple cells in the same column(spaces removed) then automatically Excel should show or display the AVERAGE: <Average value> SUM: <total Sum> COUNT: <count value>
at the below status bar or bottom ribbon.
Say, AVERAGE: 175.49 COUNT: 2 SUM: 350.98
This type of information is not showing at the bottom. Only i'm able to see COUNT: 2
alone....why?
I want in General Format only. No any special formats.
I'm using MS Excel 2013
Using Excel 2007 brettdj answered this for me. This is what worked for me and it was SIMPLE!!
To remove the CHAR(160) directly without a workaround formula go to Find & Replace
in the Find What hold ALT and type 0160 using the numeric keypad then Leave Replace With as blank and select Replace All
First make sure you have the column Formatted as you would like. Make sure it is a number with 2 decimal places (or how ever many you need), then also make sure that there is no Indents (Maybe you think the Indent is a space?) And that you have it Aligned to the Left, Or where you want the Data To be. This alone should take care of your issue.
If that doesn't work here a list of possible solutions.
If nothing works could you please share Why you would like to remove the space? As in what you are trying to do with the data? As maybe that will open more solutions
With Ole Henrik Skogstrøm's Suggestion added Value around the functions to get the result as a value.
In your case, since you always have a string of numbers, where you want to remove just the first character (a space), this formula should work:
The numbers can vary in length, important is only, that you want to remove just 1, (or 2, or 3 etc) characters. It will still work. {If you had 2 empty spaces in front, then you would use in the formula -2, if three -3, etc)
However, if you had always a different amount of blanks in your string of numbers, like I had, you could use this formula, which worked for me:
,assuming that the issue you are facing is code "160". That you can find by typing:
=code(A1)
, which in my case gave me the result "160". Therefore char(160) in the formula above.Not the answer you're looking for? Browse other questions tagged excel excel-2013 or ask your own question.