Ini
tial
ize
to do
this (you could call it any thing you want, like
House
keeper
,
Maid
, or
Mom
).
Let’s imagine that you have two slides (slides 2 and 3) that will show stars when
the correct an swer is chosen. If the stars are the fourth ob ject on the slides, your
Ini
tial
ize
pro cedure might look something like this:
Sub Ini
tial
ize()
ActivePresentation.Slides(2).Shapes(4).Vis
ible = False
ActivePresentation.Slides(3).Shapes(4).Vis
ible = False
End Sub
You could add something to this pro cedure to move to the next slide, or you
can do all your initializing from this pro cedure and have another procedure take
care of other stuff. So let’s add a
GetStarted
pro cedure to do the other stuff as
well as call the procedure
Ini
tial
ize
.
Sub GetStarted()
Ini
tialize 'Hide the stars
YourName 'Ask for the name
ActivePresentation.SlideShowWindow.View.Next 'Go to the next slide
End Sub
This procedure will be linked to the but ton on the title slide. As the comments in -
dicate, it will use the
Ini
tial
ize
pro cedure to hide the stars, it will use the
YourName
procedure to ask for a name, and it will use
ActivePresentation.SlideShowWindow.View.Next
to go to the next
slide. As al ways, because this procedure calls the
YourName
pro cedure and the
Ini
tial
ize
pro cedure, these pro cedures must be in cluded in your module
along with the dec laration (
Do'stlaringiz bilan baham: |