Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 09-08-2016, 03:53 AM
macropod's Avatar
macropod macropod is offline Bold a sentence containing an em dash Windows 7 64bit Bold a sentence containing an em dash Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,375
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

Try a wildcard Find/Replace, where:
Find = [!^13^11]@^0151[!^13^11]@[^13^11]


Replace = ^&
and you specify the replacement format as bold. As a macro, this might be implemented along the following lines:
Code:
Sub Demo()
Application.ScreenUpdating = False
With ActiveDocument.Range
  With .Find
    .ClearFormatting
    .Text = "[!^13^11]@^0151[!^13^11]@[^13^11]"
    With .Replacement
      .ClearFormatting
      .Text = "^&"
      .Font.Bold = True
    End With
    .Forward = True
    .Wrap = wdFindContinue
    .Format = True
    .MatchWildcards = True
    .Execute Replace:=wdReplaceAll
  End With
End With
Application.ScreenUpdating = True
End Sub
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Bold a sentence containing an em dash Adding bold colons at end of bold row headings bertietheblue Word Tables 2 07-26-2015 07:26 AM
Bold a sentence containing an em dash Text in #1 is made bold, rest of the document is edited, text in #1 is now not bold footer-assistance Word 1 06-29-2015 03:49 AM
Bold a sentence containing an em dash Delete does not bring second sentence closer to first sentence Andoheb Word 29 07-03-2014 01:48 PM
Format Bold in one line makes all lines bold Nitte Word 2 02-07-2013 12:34 AM
Bold a sentence containing an em dash Need Word to change -- (dash,dash) into one long dash. Bobosmite Word 2 05-06-2011 04:21 AM

Other Forums: Access Forums

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