field with spaces that need to be removed

guaya81

New Member
Joined
May 9, 2018
Messages
25
Good day guys and girls

I have an issue and need to find a way to resolve it
there is a column that has an amount and in that field, the number has 6 spaces and cant removed with formula I have to do it manually

$ 1,632.00 I try to replace, =substittute(h2," ",""), =substittute(h2," ","") and they dont work for me

do you have any suggestion


thanks
 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
Good day guys and girls

I have an issue and need to find a way to resolve it
there is a column that has an amount and in that field, the number has 6 spaces and cant removed with formula I have to do it manually

$ 1,632.00 I try to replace, =substittute(h2," ",""), =substittute(h2," ","") and they dont work for me
If you copied the values from another source (especially if you did so from a web page), then those spaces are probably not regular spaces (ASCII 32), rather, they are probably non-breaking spaces (ASCII 160). Give this formula a try...

=SUBSTITUTE(H2,CHAR(160),"")
 
Upvote 0
Mr. Rick

thank you I didn't work but I guess is another issue and I can use your formula in another place better, always learning something

thanks
 
Upvote 0
If the spaces are after the $ sign, put this in a blank cell & what does it return?
=CODE(MID(H2,2,1))
 
Upvote 0
Mr. Rick

thank you I didn't work but I guess is another issue and I can use your formula in another place better, always learning something
You should answer Fluff's question in Message #4 as what he is thinking about could be behind your problem. Following up on my post though, perhaps you have a mix of normal and non-breaking spaces. With that in mind, give this formula a try...

=SUBSTITUTE(SUBSTITUTE(H2,CHAR(160),"")," ","")
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top