1 year ago
#77221

Ken
Using VBA to add automation to a line in a text field shape
I understand VBA in EXCEL very well, but PowerPoint is something else. So far I have generated my slides from a text file. The title is really a question and the box below is four possible answers. I use this code to build the possible answers.
Sld.Shapes(2).TextFrame.TextRange = line1 & vbNewLine & _
line2 & vbNewLine & _
line3 & vbNewLine & _
line4 & vbNewLine
For each question I know which LineX is the correct answer. When, in the slide show, I click for the next slide, I want the correct answer to change to Red and then spin one time. The next click takes me to the next slide I can manually highlight the correct answer and then add to two automation events,change fort color and spin clockwise one time in .5 seconds. But how to do that with VBA?
First select the correct line in shape 2, and then added the automation. Point me to somewhere or share some code. I have a lot of slides over 600 so manual is not a real option.
Thanks.
vba
text
automation
powerpoint
0 Answers
Your Answer