How to find Symbols

V

Vijay J.

I use a lot of symbols in text (Word 2000): I insert them
by using Insert>Symbol and then selecting the desired
symbol in the grid and then pressing Insert again. Is
there a way to find or search these symbols? I find this
way of inserting symbols very convenient, however,
Symbols inserted this way still show the basic text font
(i.e., for eg, Times New Roman), whereas symbols inserted
by typing a character and then changing Font to "Symbol"
makes it easy to Find these symbols, but I need to know
beforehand which chacter represents which symbol, which
is not very convenient.
Vijay
 
K

Klaus Linke

Hi Vijay,

You can copy/paste the symbol into "Find what" (Ctrl+C, Ctrl+V).

Word versions before Word2003 have several bugs and problems finding
symbols.
If you select some symbol or regular Unicode character and run the macro
below, it should stop at the next identical character (same code, same
font) in any Word version ... but I only tested it in Word2002/2003.

To find any symbol (non-Unicode) character, you can use a wildcard search
for
.Text = "[" & ChrW(&HF021) & "-" & ChrW(&HF0FF) & "]"

This works because Word uses codes between U+F021 and U+F0FF for
"decorative"/symbol fonts.
Word2000 and 2002 have problems if you want to search for the font that was
used...
Therefore the macro uses the "Insert > Symbol" dialog to get the font.

You can also google for some macros I posted (SymbolsUnprotect,
SymbolsProtect) that turn all protected symbols inserted from the dialog
into "regular" unprotected symbols -- showing the symbol font --, and vice
versa.

Regards,
Klaus


Dim myFont As String
Dim myCharNum As Long
With Dialogs(wdDialogInsertSymbol)
myFont = .Font
myCharNum = .CharNum And &HFFFF&
End With
' If regular (Unicode) font:
If Left(myFont, 1) = "(" Then
myFont = Selection.Font.Name
End If
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = ChrW(myCharNum)
.Forward = True
.Wrap = wdFindContinue
.Format = False
.MatchCase = True
.MatchWildcards = False
End With
While Selection.Find.Execute
' Stop if same symbol font or current style's font
Select Case Dialogs(wdDialogInsertSymbol).Font
Case myFont
Exit Sub
Case Else
If Left(Dialogs(wdDialogInsertSymbol).Font, 1) = "(" _
And Selection.Font.Name = myFont Then
Exit Sub
End If
End Select
Wend
 
R

Robert M. Franz

Hi Klaus

Klaus Linke wrote:
[..]
You can also google for some macros I posted (SymbolsUnprotect,
SymbolsProtect) that turn all protected symbols inserted from the dialog
into "regular" unprotected symbols -- showing the symbol font --, and vice
versa.

Ahh, thanks Klaus -- this might come in handy, so I had to dig that one up.

FWIW, the original thread was in German, but that shouldn't bother
anybody (well, it doesn't bother *me* ;-)):

http://groups.google.com/[email protected]&output=gplain

Greetinx from Switzerland
..bob
 
V

Vijay J.

Thanks a lot Klaus for your reply. Please find my
feedback inserted in between:

-----Original Message-----
You can copy/paste the symbol into "Find what" (Ctrl+C,
Ctrl+V).


This didn't work for me. I tried copying and pasting a
symbol Delta (looks like a triangle shape, and which was
originally inserted in the text using Insert>symbol).
When pasted in the find box, it changes in appearance to
letter D, and when I find it, it finds all d and D.

To find any symbol (non-Unicode) character, you can use a wildcard search
for
.Text = "[" & ChrW(&HF021) & "-" & ChrW(&HF0FF) & "]"

This works because Word uses codes between U+F021 and U+F0FF for
"decorative"/symbol fonts.


I pasted this line of text in the Find box, and
ticked 'Use Wildcards'. (Sorry if I misunderstood totally
what you meant). The search gives no result, saying it
can't find the search item. Please advise. If it had
worked for me, would have been extremely useful.

Dim myFont As String
Dim myCharNum As Long
With Dialogs(wdDialogInsertSymbol)
myFont = .Font
myCharNum = .CharNum And &HFFFF&
End With
' If regular (Unicode) font:
If Left(myFont, 1) = "(" Then
myFont = Selection.Font.Name
End If
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = ChrW(myCharNum)
.Forward = True
.Wrap = wdFindContinue
.Format = False
.MatchCase = True
.MatchWildcards = False
End With
While Selection.Find.Execute
' Stop if same symbol font or current style's font
Select Case Dialogs(wdDialogInsertSymbol).Font
Case myFont
Exit Sub
Case Else
If Left(Dialogs(wdDialogInsertSymbol).Font, 1) = "(" _
And Selection.Font.Name = myFont Then
Exit Sub
End If
End Select
Wend


This macro works excellently for me, however, it finds
only that symbol which was selected before running macro.
Nevertheless, it is very useful to me.
 
K

Klaus Linke

Hi Vijay,
(Ctrl+C, Ctrl+V).


This didn't work for me. I tried copying and pasting a
symbol Delta (looks like a triangle shape, and which was
originally inserted in the text using Insert>symbol).
When pasted in the find box, it changes in appearance to
letter D, and when I find it, it finds all d and D.

I think that can happen only in some older versions (Word2000), only before
you saved the document, and only if you didn't use "Insert > Symbol".
You can try if it works after saving (Ctrl+S)?
Usually, the character should display as some Wingding in the dialog.
To find any symbol (non-Unicode) character, you can use
a wildcard search for
.Text = "[" & ChrW(&HF021) & "-" & _
ChrW(&HF0FF) & "]"
[...]
This works because Word uses codes between U+F021
and U+F0FF for "decorative"/symbol fonts.


I pasted this line of text in the Find box, and
ticked 'Use Wildcards'. (Sorry if I misunderstood totally
what you meant). The search gives no result, saying it
can't find the search item. Please advise. If it had
worked for me, would have been extremely useful.

This line was meant to be used in a "Find/Replace" macro, to replace the
line starting with ".Text = ".

It's very cumbersome to type it in the "Find what:" box in the user dialog,
though it can be done:
You need "[x-y]" without the quotes in "Find what:",
and instead of "x" type "Alt+61473",
instead of "y" type "Alt+61695".
(hold Alt-key, and type the number on the numeric keypad on the right side
of the keyboard)

Those two characters should display in Wingdings, as a pencil and as a
"Windows flag".

One of the macro projects that came with old Word versions (Support.Dot or
Macros#.dot, where # is some number) had a macro to find symbols. Since it
needs a custom dialog to enter the font and choose the character, I can't
paste it here.

Regards,
Klaus
 
V

Vijay J.

Hi Klaus,
Thanks for the reply. I tried the suggestions, but .....I
think I am having a bad time. Please see my comments
inserted.
-----Original Message-----
Hi Vijay,


I think that can happen only in some older versions (Word2000), only before
you saved the document, and only if you didn't use "Insert > Symbol".
You can try if it works after saving (Ctrl+S)?
Usually, the character should display as some Wingding
in the dialog.


I saved the document, and also made sure the symbols are
inserted using Insert>symbol. (As a test, I also included
some symbols in the text using font 'symbol'). However,
the problem still remained, i.e. as the symbols are
copied to the Find box, they become normal letters, and
the Find finds only the normal letters, not the symbols.
Same thing happens with the symbols with font 'symbol'


To find any symbol (non-Unicode) character, you can use
a wildcard search for
.Text = "[" & ChrW(&HF021) & "-" & _
ChrW(&HF0FF) & "]"
[...]
This works because Word uses codes between U+F021
and U+F0FF for "decorative"/symbol fonts.


I pasted this line of text in the Find box, and
ticked 'Use Wildcards'. (Sorry if I misunderstood totally
what you meant). The search gives no result, saying it
can't find the search item. Please advise. If it had
worked for me, would have been extremely useful.

This line was meant to be used in a "Find/Replace" macro, to replace the
line starting with ".Text = ".

I tried this in the macro. But it didn't find any symbols.
(The cursor doesn't move from its position when I run the
macro, though there are symbols present ahead in the text
to be found). Just to test that my macro is correct
otherwise, I tried replacing the .Text line with some
normal text, and it worked fine.
It's very cumbersome to type it in the "Find what:" box in the user dialog,
though it can be done:
You need "[x-y]" without the quotes in "Find what:",
and instead of "x" type "Alt+61473",
instead of "y" type "Alt+61695".
(hold Alt-key, and type the number on the numeric keypad on the right side
of the keyboard)

Those two characters should display in Wingdings, as a pencil and as a
"Windows flag".

Yes, the pencil symbol and Flag symbol correctly
displayed in the Find box, but the result of Find is the
same..., it gives no results.
 
K

Klaus Linke

Hi Vijay,

Sorry, I'm at a complete loss about your problems!
What is the version? The only one I never used for any length of time is
Word 97, so that might explain the differences...

Regards,
Klaus
 
K

Klaus Linke

Hi again,

Sorry you have such a bad time :-/
This didn't work for me.

Sorry, my fault. It doesn't work in Word2000.
To find any symbol (non-Unicode) character, you can
use a wildcard search for
.Text = "[" & ChrW(&HF021) & "-" & _
ChrW(&HF0FF) & "]"
[...]
This works because Word uses codes between U+F021
and U+F0FF for "decorative"/symbol fonts.

I tried this in the macro. But it didn't find any symbols.
(The cursor doesn't move from its position when I run
the macro, though there are symbols present ahead in the
text to be found). Just to test that my macro is correct
otherwise, I tried replacing the .Text line with some
normal text, and it worked fine.

You used
.MatchWildcards = True
in your macro? It's a wildcard search...
It's very cumbersome to type it in the "Find what:"
box in the user dialog,
though it can be done:
You need "[x-y]" without the quotes in "Find what:",
and instead of "x" type "Alt+61473",
instead of "y" type "Alt+61695".
(hold Alt-key, and type the number on the numeric
keypad on the right side of the keyboard)

Those two characters should display in Wingdings, as a
pencil and as a "Windows flag".
Yes, the pencil symbol and Flag symbol correctly
displayed in the Find box, but the result of Find is
the same..., it gives no results.

That still baffles me. It definitely works here (Word2000/Win98).
Again, is "Match wildcards" checked in the dialog?

You can also get the decimal code from the "Insert > Symbol" dialog:
Select the Wingdings character, open the dialog, and click on "Shortcut
key".
The code should show under "Description" -- for example, "Wingdings:
61537".
You can then use ^u61537 in "Find what:" (not using wildcards this time).

I still hope you get something going to find those symbols!

<fingers crossed>
Klaus
 
V

Vijay J.

It has worked this time !!!
Thanks Klaus, it is working now. Sorry, I missed the
important thing that I need to use "Wildcard" search,
though you mentioned it in previous reply.
You used
.MatchWildcards = True
in your macro? It's a wildcard search...
You need "[x-y]" without the quotes in "Find what:",
and instead of "x" type "Alt+61473",
instead of "y" type "Alt+61695".
(hold Alt-key, and type the number on the numeric
keypad on the right side of the keyboard)

That still baffles me. It definitely works here (Word2000/Win98).
Again, is "Match wildcards" checked in the dialog?


Both these now worked for me, and my problem is solved
now. Thanks a lot for your suggestions and patience.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top