![]() |
#1
|
|||
|
|||
![]() Hi, When I copy text from pdf, many hyphenation appear, I tried many search condition to look for "- " but all failed The only way which recognize that is when I type "^?‑ " So it require any character dash space Now I want to keep the character and remove dash space I used ^? again in replace box but it's not valid Any modification to such macro Code:
Sub RemoveDashSpace() Dim oRng As range If Len(Selection.range) = 0 Then MsgBox "Select the text first", vbCritical Exit Sub End If Set oRng = Selection.range With oRng.Find .ClearFormatting .Replacement.ClearFormatting .text = "" .Replacement.text = "" .Forward = True .Wrap = wdFindStop .Format = False .MatchCase = False .MatchWholeWord = False .MatchAllWordForms = False .MatchSoundsLike = False .MatchWildcards = False .Execute Replace:=wdReplaceAll End With End Sub |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
word hyphenation | rogiburn | Word | 3 | 05-12-2021 10:24 AM |
![]() |
technofleep | Word | 7 | 06-28-2016 04:39 PM |
![]() |
barrage | Word | 1 | 12-16-2015 02:59 PM |
![]() |
spc94 | Word VBA | 3 | 06-25-2015 04:46 AM |
Copied shape/text box pastes as an image in Word | spectator | Word | 0 | 06-04-2014 08:45 AM |