Powerful PowerPoint for Educators: Using Visual Basic for Applications to Make PowerPoint Interactive


Download 1.37 Mb.
Pdf ko'rish
bet40/191
Sana08.05.2023
Hajmi1.37 Mb.
#1442581
1   ...   36   37   38   39   40   41   42   43   ...   191
Bog'liq
2.2. Powerful PowerPoint For Educators

Changing a But ton
You might want to make three types of changes to your but ton: changing
the PowerPoint at tributes of a but ton, such as size shape, or text; changing which
script a button uses (in cluding add ing a script if the but ton isn’t tied to one); and
changing what the script does that the but ton uses.
To change the at tributes of a but ton, you would use traditional PowerPoint
features. For example, you can change the text in the but ton by right-clicking on
the but ton and choosing “Edit Text” (“Add Text” if the but ton doesn’t al ready
have any text) from the flyout menu. You can use any of the drawing tools to
change the size, shape, color, etc., of the button.
If you created your but ton and didn’t tie it to a script, you can right-click on
the but ton and choose “Ac tion Set tings” from the flyout menu. Al ternatively,
you can left-click on the but ton to select it, go to the Slide Show menu, and
choose “Ac tion Set tings.” Once in the Action Settings dialog box (see Fig ure
4.5, page 45), you can choose Run Macro. If you had as sociated your but ton with
the wrong script, you can change which script the but ton runs in the Action Set-
tings dialog box. If you have more than one script, you can choose a different
script from the pull-down menu un der Run Macro. If you don’t want your but ton
to run any script, click None in the Action Settings dialog box.
Be ware! If you have added text to your but ton, it is easy to
accidentally link the text rather than the but ton. Generally,
you want the entire but ton to activate your script, not just
the text in side the but ton. You can tell that you have linked
the text be 
cause PowerPoint will generally un 
derline
linked text. To en sure that you link the entire but ton, left
click on the but ton to select it. Be sure that you do not have
a cursor flashing in the text. If you do, left click anywhere
on the but ton that is out side of the text. At this point you
can ei ther choose “Ac tion Set tings” from the Slide Show
menu or right-click on the bor 
der of your but 
ton and
choose “Ac tion Set tings” from the flyout menu. Be cause
PowerPoint allows you to link text separately from a but -
ton, you easily can get confused. If you have linked the text
and you later check to see which script the but ton activates,
your Action Settings dialog box will in dicate “None.” Be
careful to always link the entire button to avoid this
confusion.
46 Getting Started with VBA

Download 1.37 Mb.

Do'stlaringiz bilan baham:
1   ...   36   37   38   39   40   41   42   43   ...   191




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling