Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 10-25-2014, 12:01 AM
rsrasc rsrasc is offline Removing Duplicate Text in a Document Windows 7 64bit Removing Duplicate Text in a Document Office 2010 64bit
Competent Performer
Removing Duplicate Text in a Document
 
Join Date: Mar 2014
Location: Germany
Posts: 148
rsrasc is on a distinguished road
Default

Hi Macropod,

Not sure if I am the problem (surely I am) but I can't get it to work. Can you check the below code?

Thanks,


PHP Code:
Sub macroDeletingDoubleMCQ()
'
lMacroDeletingDoubleMCQ
'
'
    
Selection.Find.ClearFormatting
    Selection
.Find.Replacement.ClearFormatting
    With Selection
.Find
        
.Text "Question #[0-9]@ \(ACCCC*\)^13)\1"
        
.Replacement.Text "\1"
        
.Forward True
        
.Wrap wdFindContinue


        
.Format False
        
.MatchCase False
        
.MatchWholeWord False
        
.MatchAllWordForms False
        
.MatchSoundsLike False
        
.MatchWildcards True
    End With
    Selection
.Find.Execute Replace:=wdReplaceAll
End Sub 
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Locating and removing large, duplicate blocks of copy in word markaffleck Word 2 06-05-2014 10:12 PM
Removing blank pages at the end of a document Xanzia Word 3 06-01-2014 11:13 AM
Removing Duplicate Text in a Document Finding duplicate sentences in a document seascape Word VBA 1 02-18-2014 12:31 AM
Removing duplicate index entries Bengt Word 5 03-01-2013 02:01 AM
Saving Word document creates a duplicate transparent file bbailey Word 0 12-05-2009 10:54 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 10:51 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