Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #6  
Old 06-02-2017, 08:14 PM
gmayor's Avatar
gmayor gmayor is offline Moving to a particular word in a document Windows 10 Moving to a particular word in a document Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,142
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

Without seeing your macro it is difficult to advise how to add to it. Basically you set a bookmark to the range that you have found as you add it to your log.

To go to the bookmark - let's assume you have added bookmarks bm1 to bm10 i.e a number following 'bm'. Then the following macro will prompt for a number and then select the numbered bookmark and delete the bookmark (but not its content).

Code:
Sub GetBM()
Dim sBM As String
    On Error GoTo lbl_Exit
    sBM = InputBox("Go to which bookmark number")
    With ActiveDocument.Bookmarks("bm" & sBM)
        .Range.Select
        .Delete
    End With
lbl_Exit:
    Exit Sub
End Sub
__________________
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
 

Tags
editing



Similar Threads
Thread Thread Starter Forum Replies Last Post
Moving to a particular word in a document moving charts around a word document rich_cirillo Word 1 05-13-2014 07:10 PM
Moving Quick Parts with the document derohanes Word 4 10-23-2013 09:30 PM
Moving to a particular word in a document Adding and Moving parts of a document in Word PauledInAction Word 4 07-13-2012 02:38 PM
Moving to a particular word in a document Moving a Long Document clpix Word 1 01-14-2010 08:55 PM
problem moving text to blank document carolanshaw Word 0 03-23-2009 08:45 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:05 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft