![]() |
#1
|
|||
|
|||
![]()
Hi,
I made a macro to duplicate selected words according to its sequence in a sentence Code:
Sub DuplicateSelectedWords() Dim oRng As range If Len(Selection.range) = 0 Then MsgBox "Select the text first", vbCritical Exit Sub End If Set oRng = Selection.range oRng.Copy oRng.InsertAfter (oRng.text) End Sub For individual selection, it just duplicate only one word, may be the first word or second or the last. So please how to edit the current macro to duplicate all selected words ( individual selection) also. Thanks |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
ranjan | Word VBA | 7 | 08-26-2021 02:17 AM |
Page numbers not following. All sections continuous, link to previous selected. | ClaireP | Word | 4 | 07-07-2020 08:12 AM |
![]() |
Bookmaster | Word VBA | 7 | 02-03-2015 04:30 PM |
![]() |
cinvest | Word | 1 | 09-29-2014 08:34 PM |
Why Words doesn’t show the style of the selected words automatically???? | Jamal NUMAN | Word | 0 | 04-14-2011 03:20 PM |