Hello, everyone!
I woild like to see macro to copy selected text to the end of the document.\
Is this possible?
Hello, everyone!
I woild like to see macro to copy selected text to the end of the document.\
Is this possible?
That's fairly simple, though I assume you mean the 'highlighted' text and not 'selected' text.
Sub CopyTextatEnd() Dim oRng As Range Dim sText As String: sText = "" Set oRng = ActiveDocument.Range With oRng.Find .Highlight = True Do While .Execute sText = sText & vbCr & oRng.Text oRng.Collapse 0 Loop End With ActiveDocument.Range.InsertAfter sText lbl_Exit: Set oRng = Nothing Exit Sub End Sub
Graham Mayor - MS MVP (Word) 2002-2019
Visit my web site for more programming tips and ready made processes
http://www.gmayor.com
Excellent!!!
Thank u a lot!!