Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 05-30-2012, 12:58 AM
ubns ubns is offline Deleteing specific text in word document Windows 7 32bit Deleteing specific text in word document Office 2010 32bit
Competent Performer
Deleteing specific text in word document
 
Join Date: Apr 2012
Posts: 177
ubns is on a distinguished road
Default Deleteing specific text in word document

Hi,
I have a document with more than 80 pages. These are my summary from kindle books.
Is it possible to delete all the instances of the following text.

1) You have 91 highlighted passages
2) You have 0 notes


3) • Delete this highlight • Undo deletion
4) B000SEI4V0 53792 Note: Add a note
5) Read more at location 358

Please note that numbers or text in green color will vary throughout the document.


Sometimes in a document; there is more than one space between the parapgrahs; I mean line spacing. Can we reduce it to one by using macro?

Reply With Quote
  #2  
Old 05-31-2012, 10:38 PM
macropod's Avatar
macropod macropod is offline Deleteing specific text in word document Windows 7 64bit Deleteing specific text in word document Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,963
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi umesh,

You can do that quite simply with a series of wildcard Find/Replace actions. For example:
Find = You have [0-9]{1,} highlighted passages
Replace = nothing
Find = You have [0-9]{1,} notes
Replace = nothing
Find = • Delete this highlight • Undo deletion
Replace = nothing
Find = B000?@: Add a note
Replace = nothing
Find = Read more at location [0-9]{1,}
Replace = nothing

You could use the macro recorder to capture these as a macro.

Likewise with the paragraph spacing:
Find = ^13{2,}
Replace = ^p
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Deleteing specific text in word document Delete specific text Jackson Word VBA 16 12-06-2019 08:24 PM
Deleteing specific text in word document Using Hyperlink to open Word Document at Specific Header rossi45 Word 2 05-04-2012 06:03 PM
Deleteing specific text in word document how to transfer multiple excel cells into specific place in word document by formulas anton Excel 1 12-20-2011 03:56 AM
Deleteing specific text in word document Need help extracting specific text from one doument to another with macro/VBA. zsmithku Word 1 04-15-2011 03:46 PM
Deleteing specific text in word document Setting focus to specific word document from UserForm SaneMan Word VBA 5 04-01-2011 03:11 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:15 PM.


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