Hi
first of all please let me inform the question i am asking is about power point VBA but am not sure about the right forum to ask the question. Kindly direct me to the right place if anyone knows where i can get my answer.
I am trying to build a macro in powerpoint application which would go through all the shapes of all the slides and find particular values and highlight them.
Now the value i would be searcing for is not of fixed length for example i am looking for a hyphen (-) which has 2 numbers both at the begining and at end (i.e 12-34, 79-30..etc)
as you can see the numbers could be anything but the format would be the same. Kindly advice how can i write a macro for this.
I have a macro in word VBA which could do the above thing easily, but i am just unable to figureout a way in powerpoint. (But i hope it should be possible in powerpoint as well)
below is the code example
[code\]
Sub trial()
Options.DefaultHighlightColorIndex = wdPink
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
Selection.Find.Replacement.Highlight = True
With Selection.Find
.Text = "^#-^#"
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchByte = False
.CorrectHangulEndings = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub
[\code]
Please help...
Regards,
Premanshu
first of all please let me inform the question i am asking is about power point VBA but am not sure about the right forum to ask the question. Kindly direct me to the right place if anyone knows where i can get my answer.
I am trying to build a macro in powerpoint application which would go through all the shapes of all the slides and find particular values and highlight them.
Now the value i would be searcing for is not of fixed length for example i am looking for a hyphen (-) which has 2 numbers both at the begining and at end (i.e 12-34, 79-30..etc)
as you can see the numbers could be anything but the format would be the same. Kindly advice how can i write a macro for this.
I have a macro in word VBA which could do the above thing easily, but i am just unable to figureout a way in powerpoint. (But i hope it should be possible in powerpoint as well)
below is the code example
[code\]
Sub trial()
Options.DefaultHighlightColorIndex = wdPink
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
Selection.Find.Replacement.Highlight = True
With Selection.Find
.Text = "^#-^#"
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchByte = False
.CorrectHangulEndings = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute Replace:=wdReplaceAll
End Sub
[\code]
Please help...
Regards,
Premanshu