View Single Post
 
Old 05-20-2023, 07:29 AM
gmayor's Avatar
gmayor gmayor is offline Windows 10 Office 2019
Expert
 
Join Date: Aug 2014
Posts: 4,144
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

Change the two instances of oRng.Select to oRng.Copy and the cursor will remain where it was when the macro was run and the address will be copied to the clipboard, which seems to be the aim.
After the second instance enter
Code:
Else
    MsgBox "Address not found"
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote