keyboard shortcut

G

Guest

Help Please. .
So as to underline in a colour different from that of the
text and instead of clicking on “Format – Font†etc. constantly I decided to
set up a keyboard shortcut so clicked on “Toolsâ€; “Customise.†“Keyboardâ€
“Categories†“All Commandsâ€. “Active Object†then scrolled down to “Draw Set
Line Colour†and assigned a keyboard shortcut but it does not seem to give
the desired affect. Am I missing some element or is this the wrong way to set
up this feature?
Thanks Basil B
 
G

Guest

Basil:

There is no single command that matches what you're trying to do, so you
won't be able to assign a keyboard shortcut to an existing command.

It would probably be simplest for you to define a character style that has
no other attributes than an underline of the color you want to use. To
underline the selected word, phrase or paragraph, you'd then apply that
character style to the selection.

Once you've created the style you CAN use a keyboard shortcut to assign it.
You'd use Tools > Customize > Keyboard as you've done, but in the Categories
list select Styles, then in the Styles list, find your underline character
style.

To see (roughly) what happens when you underline the selected word with a
custom color -- as you've been doing manually -- record a macro of your
actions. Then select and edit the macro to see the result. It might look
something like:

Sub x()
'
' x Macro
' Macro recorded 5/4/2007 by David Chinell
'
With Selection.Font
.Name = "Arial"
.Size = 12
.Bold = True
.Italic = False
.Underline = wdUnderlineSingle
.UnderlineColor = wdColorRed
.StrikeThrough = False
.DoubleStrikeThrough = False
.Outline = False
.Emboss = False
.Shadow = False
.Hidden = False
.SmallCaps = False
.AllCaps = False
.Color = wdColorGray50
.Engrave = False
.Superscript = False
.Subscript = False
.Spacing = 0
.Scaling = 100
.Position = 0
.Kerning = 0
.Animation = wdAnimationNone
End With
End Sub

As you can see, every setting possible in the Font dialog box is there in
the command. If you ran this macro on a selection, it would not only
underline it, but set the font and size and so on. So you'd want to delete
everythig except the underline parts:

Sub x()
'
' x Macro
' Macro recorded 5/4/2007 by David Chinell
'
With Selection.Font
.Underline = wdUnderlineSingle
.UnderlineColor = wdColorRed
End With
End Sub

Once you saved this macro you could then assign a keyboard shortcut by
selecting Macros in the Categories list and searching for your macro in the
Macros list.

Probably a lot more than you wanted to know.

Bear
 

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

Similar Threads


Top