The following macro will give the ANSI code of any selected character:
Sub ANSIValue()
S1$ = "Because the selected text contains"
S2$ = " characters, not all of the ANSI values will be displayed."
S3$ = "ANSI Value ("
S4$ = " characters in selection)"
S5$ = " character in selection)"
S6$ = "Text must be selected before this macro is run."
S7$ = "ANSI Value"
Dim strSel As String
Dim strNums As String
Dim LastFourChar As String
Dim iPos As Integer
strSel = Selection.Text
If Len(strSel) 0 Then
For i = 1 To Len(strSel)
strNums = strNums + Str(Asc(Mid(strSel, i)))
Next i
strNums = LTrim(strNums)
If Len(strNums) 255 Then
LastFourChar = Mid(strNums, 252, 4)
strNums = Left(strNums, 251) + Left(LastFourChar, _
4 - InStr(" ", LastFourChar))
MsgBox S1$ + Str(Len(strSel)) + S2$
End If
If Len(strSel) = 1 Then S4$ = S5$
MsgBox strNums, 0, S3$ + LTrim(Str(Len(strSel))) + S4$
Else
MsgBox S6$, 0, S7$
End If
End Sub
--
Graham Mayor - Word MVP
My web site
www.gmayor.com
Word MVP web site
http://word.mvps.org
Graham Mayor wrote:
You can find any character using its ANSI or UNICODE number in the
search tool - see http://www.gmayor.com/replace_using_wildcards.htm
Dave wrote:
JoAnn Paules - another good idea - But it looks like Greg's routine
doesn't include the characters in question.
sniptcebob "would you post an excerpt? "
Great idea - turns out, tho, that when I paste the sample said marks
disappear. Can I attach a Word document on this list???
snip"Nothing but calm on my end"
Good
snip"There is no such thing as a "backspace character".
Well, OK, but I got pages of them
BTW, I find none of these characters in my Word symbols library.
Stark reality is starting to set in :-).
Dave
"JoAnn Paules [MVP]" wrote in message
.. .
That's a completely different question. Greg Maxey has something
that may help.
http://gregmaxey.mvps.org/Clean_Up_Text.htm
--
JoAnn Paules
MVP Microsoft [Publisher]
"Dave" wrote in message
...
Let's all remain calm everybody, the OP forgot to mention something
key. Shall we start over.
I am the lucky recipient of a very lengthy report contained in,
unfortunately not attached to, an email message (if you think this
OP is a problem you should be so lucky as to be working with the
sender). My duty is to edit this doc extensively, then combine it
with others, etc., etc.
When you C/P from the email into Word, you get a zillion line
ending/backspace/paragraph characters, with formatting to match.
Really ugly.
I was hoping there was a way to find/replace to clean this mess up.
Dave
"JoAnn Paules [MVP]" wrote in message
.. .
Okay. I was thinking more along the lines of a
letter/number/symbol and not a command. Perhaps the OP needs to
clarify what he/she is doing. --
JoAnn Paules
MVP Microsoft [Publisher]
"tcebob" handle @ gwi.net wrote in message
...
Well, actually, there is. (008) But whether Word uses it, I don't
know; probably not.
There is an overtype format for making overlines and so forth but
I can't say how it
actually works.
The backspace used to work fine on dot matrix printers and
Selectrics, together with line
feed (without carriage return). I programmed some tables with
these characters and it was
fun to watch the printer jog back and forth, up and down.
rs
"JoAnn Paules [MVP]" wrote in
message news
There is no such thing as a "backspace character".
--
JoAnn Paules
MVP Microsoft [Publisher]
"Dave" wrote in message
...
How can I do a Find and Replace on the backspace character?. I
don't see how to get the backspace character into the 'Find
What" slot. Thx
Dave