EDN Admin
Well-known member
Hi to all, i have a little problem, i need to find text formated in strikethrough and put in between brackets.
The following code can replace every character in strikethrough by an "*" but i need the found text to be between brackets "[]":
Dim newWord As Word.Application = Nothing Dim newDocs As Word.Documents = Nothing Dim newDoc As Word.Document = Nothing newWord = New Word.Application() newDocs = newWord.Documents newDoc = newDocs.Open("C
rueba.doc") newDoc.Range.Tables(1).Columns(2).Select() newWord.Selection.Find.ClearFormatting() newWord.Selection.Find.Font.StrikeThrough = TruenewWord.Selection.Find.Replacement.ClearFormatting() With newWord.Selection.Find .Text = "*" .Replacement.Text = "[" & .Text &"]" .Forward = True .Wrap = Word.WdFindWrap.wdFindContinue .Format = True .MatchWildcards = True End With newWord.Selection.Find.Execute(Replace:=Word.WdReplace.wdReplaceAll) newDoc.SaveAs("C
rueba.doc") newDoc.Close() newWord.Quit()
Can anybody help me please???
Thanks in advance...
View the full article
The following code can replace every character in strikethrough by an "*" but i need the found text to be between brackets "[]":
Dim newWord As Word.Application = Nothing Dim newDocs As Word.Documents = Nothing Dim newDoc As Word.Document = Nothing newWord = New Word.Application() newDocs = newWord.Documents newDoc = newDocs.Open("C


Can anybody help me please???
Thanks in advance...
View the full article