how clean strange symbols(?þ) from Table or range

Ali M

Active Member
Joined
Oct 10, 2021
Messages
290
Office Version
  1. 2019
  2. 2013
Platform
  1. Windows
Hi experts
I face dilemma when I received file by another person .
it shows after name like this :

item?þ
itemþ?
so how can I delete these from all of my table or in used range to become like this
item
is there any macro to clean the cells in table or in used range?
this symbols cause me big troubles with another macros(can't run)
thanks
 
ok maybe I attach sample and use VB Project Explorer's Intermediate window, you will understand what I 'm talking about it , otherwise ignore that.
thank you for your time .
 
Upvote 0

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Run the code below that prints to the Immediate window. What numbers appears next to the characters that look like the one you see?
VBA Code:
Sub asceeee()
    Dim i As Long
    For i = 123 To 256
        Debug.Print ChrW(i) & " " & i
    Next
End Sub
 
Last edited:
Upvote 0
@MARK858
here is the pictures
1.PNG


2.PNG

3.PNG


4.PNG
 
Upvote 0
Odd because when I run it, there are at least 2 symbols that look like they could be it but there doesn't appear to be any in your list.

I know that the characters in the ASCII extended list vary by region but I expected it to be there somewhere.
I'm afraid that I can't do anything there.
 
Upvote 0
well my language is Arabic , I'm still surviving by searching in internet to find macro delete any ASCII symbols .
any way thanks for your trying .
 
Upvote 0
I'm still surviving by searching in internet to find macro delete any ASCII symbols

In general you use find and replace to remove ASCII characters using either Chr(ASCII number) or ChrW(ASCII number) or you use regular expressions (a bit more complicated if you aren't familiar with them)
 
Upvote 0
In general you use find and replace to remove ASCII characters using either Chr(ASCII number) or ChrW(ASCII number) or you use regular expressions (a bit more complicated if you aren't familiar with them)
so you mean it can fix my case?
if it's so . good news , bad new I don't find suitable macro to do that . I tested some macro, but does not succeed so far.:sick:
 
Upvote 0
so you mean it can fix my case?
Not unless we can find the right number and it would normally be in that range.

You could try running the macro I posted, changing the numbers up 500 at a time until you reach 9000 and might get lucky and come across it but I'm not swearing to that.

You could also see if you get a number with the formula
Excel Formula:
=CODE(RIGHT(A8,1))
or
Excel Formula:
=UNICODE(RIGHT(A8,1)
changing the A8 to a cell reference where the strange character is the last character
 
Last edited:
Upvote 0
I use the formulas and this is what I got
Cell Formulas
RangeFormula
G2:G86G2=CODE(RIGHT(A1,1))
H2:H86H2=UNICODE(RIGHT(A1,1))


You could try running the macro I posted, changing the numbers up 500 at a time until you reach 9000 and might get lucky and come across it but I'm not swearing to that.
from 131-159 , 439-500 ,8936-9000gives "?"
the rest as in pictures
1.PNG

2.PNG
 
Upvote 0
A bit odd that the 254 didn't show anything when we ran the code earlier as that is one of the umbers that appeared to match the character when I ran it.

Anyway, save a copy of your workbook then try running the code below

VBA Code:
Sub Remove8207()
  With ActiveSheet.UsedRange
      .Replace What:=ChrW(8207), Replacement:="", LookAt:=xlPart
      .Replace What:=ChrW(254), Replacement:="", LookAt:=xlPart
  End With
End Sub
 
Upvote 0

Forum statistics

Threads
1,215,963
Messages
6,127,948
Members
449,412
Latest member
montand

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