![]() |
#1
|
|||
|
|||
![]()
I have the following vba macro in msoffice word, where individual programs are written for each special word. How to write a combined and comprehensive program.
Sub Macro1() ' ' Macro1 Macro ' ' Selection.HomeKey With Selection.Find .Text = ChrW(257) .Replacement.Text = "A" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll ' Selection.HomeKey With Selection.Find .Text = ChrW(275) .Replacement.Text = "E" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll With Selection.Find .Text = ChrW(299) .Replacement.Text = "I" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll With Selection.Find .Text = ChrW(333) .Replacement.Text = "O" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll With Selection.Find .Text = ChrW(363) .Replacement.Text = "U" .Forward = True .Wrap = wdFindContinue End With Selection.Find.Execute Replace:=wdReplaceAll End Sub |
Tags |
find and replace, vba in microsoft word, vba in word |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
Kalü | Word VBA | 22 | 04-24-2018 05:35 AM |
![]() |
Dave T | Word VBA | 2 | 07-16-2015 11:23 PM |
![]() |
cdk270 | Word | 1 | 07-16-2015 01:56 AM |
![]() |
redhin | Word VBA | 5 | 03-05-2013 05:42 AM |
![]() |
tinfanide | Word | 2 | 10-06-2012 11:04 PM |