Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 11-11-2014, 06:47 AM
gmaxey gmaxey is offline Find/Replace Wildcard Needed Windows 7 32bit Find/Replace Wildcard Needed Office 2010 (Version 14.0)
Expert
 
Join Date: May 2010
Location: Brasstown, NC
Posts: 1,617
gmaxey is just really nicegmaxey is just really nicegmaxey is just really nicegmaxey is just really nicegmaxey is just really nice
Default

Code:
Sub ScratchMacro()
'A basic Word macro coded by Greg Maxey
Dim oRng As Word.Range
  Set oRng = ActiveDocument.Range
  With oRng.Find
    .Text = "Answer [A-D]{1}"
    .MatchWildcards = True
    While .Execute
      With oRng
        .MoveStart wdCharacter, 7
        .InsertBefore "("
        .InsertAfter ")"
        .Collapse wdCollapseEnd
      End With
    Wend
  End With
End Sub

__________________
Greg Maxey
Please visit my web site at http://www.gregmaxey.com/
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Find/Replace Wildcard Needed Find/Replace Wildcard Needed-Bold & Highlight rsrasc Word VBA 3 11-11-2014 03:55 PM
Find/Replace Wildcard Needed New Find/Replace Wildcard Needed rsrasc Word VBA 2 11-11-2014 09:46 AM
Find/Replace Wildcard Needed Wildcard Find and Replace Ulodesk Word 1 06-23-2014 10:26 AM
Wildcard Find/Replace deletes extra character Cosmo Word 1 06-20-2014 08:49 AM
Find/Replace Wildcard Needed Need help using WildCard Find & Replace Cayce Word 1 06-09-2014 04:17 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 01:53 AM.


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