How do I replace highlighted text - Word inserts it in front?

P

PB

When I copy some text and wish to insert it over the top of other highlighted
text (ie replace this), Word will only insert it in front of the highted text
rather than replacing the higlighted text. Any ideas?
 
P

PB

No - just through normal Microsoft office - Word.

I want to replace some words in part of a document with other words. If I
cut some (desired) text and highlight the unwanted text, then try to past
over the higlighted text all that happens is my desired text is inserted in
front of the highlighted (unwanted) text.

Normally this method would replace the unwanted text with the required text,
but there is something amiss in the partiular doument that I am working on
and I can't seem to find whatever option it is that uses paste as an "insert"
command rather than as a "replace" command. Any ideas gladly accepted since
I am working my way through a 200 page document.

PB
 
J

Jay Freedman

If you're not talking about a macro, but just copy/paste in the
regular text, go to Tools > Options > Edit and check "Typing replaces
selection".

That setting will also fix the problem if you're doing it in VBA, but
there you can make sure the setting is what you want:

Sub EditPaste()
Dim bUserSetting As Boolean
' save user's current setting
bUserSetting = Options.ReplaceSelection
' set it so it will replace
Options.ReplaceSelection = True
' paste from clipboard at selection
Selection.Paste
' restore user's setting
Options.ReplaceSelection = bUserSetting
End Sub

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so all may benefit.
 
P

PB

Perfect - thanks!

PB

Jay Freedman said:
If you're not talking about a macro, but just copy/paste in the
regular text, go to Tools > Options > Edit and check "Typing replaces
selection".

That setting will also fix the problem if you're doing it in VBA, but
there you can make sure the setting is what you want:

Sub EditPaste()
Dim bUserSetting As Boolean
' save user's current setting
bUserSetting = Options.ReplaceSelection
' set it so it will replace
Options.ReplaceSelection = True
' paste from clipboard at selection
Selection.Paste
' restore user's setting
Options.ReplaceSelection = bUserSetting
End Sub

--
Regards,
Jay Freedman
Microsoft Word MVP
Email cannot be acknowledged; please post all follow-ups to the
newsgroup so all may benefit.
 

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