R
Robin
I'm creating an interactive quiz in Powerpoint. I have created 2
possible answers to a question. Each is a button object. If the user
clicks on button 1, which is correct, then Sub Correct() in the general
script is called. If they click on button 2, then Sub Wrong()is called
up.
So far, this script works fine:
Sub Correct()
MsgBox ("Correct!")
End Sub
Sub Wrong()
MsgBox ("Sorry, that is incorrect!")
End Sub
HOWEVER, IT CALLS UP THE MESSAGE BOX, which I think is ugly and
disappears in the screen.
INSTEAD, I would like it so that when you click on the correct answer
it displays an object that has a nice bitmap associated with it.
So, I created two objects on the screen, associated them each with a
specific bitmap and named the objects Green1 and Red1. Then, using
Properties, I made them hidden.
I modified the script as follows:
Sub Correct()
ActivePresentation.Slides(40).Shapes(Green1).Visible = msoTrue
End Sub
Sub Wrong()
ActivePresentation.Slides(40).Shapes(Red1).Visible = msoTrue
End Sub
HOWEVER, NEITHER OF THESE ARE WORKING.
Am I calling these objects incorrectly? Any help would be appreciated.
Thanks!
possible answers to a question. Each is a button object. If the user
clicks on button 1, which is correct, then Sub Correct() in the general
script is called. If they click on button 2, then Sub Wrong()is called
up.
So far, this script works fine:
Sub Correct()
MsgBox ("Correct!")
End Sub
Sub Wrong()
MsgBox ("Sorry, that is incorrect!")
End Sub
HOWEVER, IT CALLS UP THE MESSAGE BOX, which I think is ugly and
disappears in the screen.
INSTEAD, I would like it so that when you click on the correct answer
it displays an object that has a nice bitmap associated with it.
So, I created two objects on the screen, associated them each with a
specific bitmap and named the objects Green1 and Red1. Then, using
Properties, I made them hidden.
I modified the script as follows:
Sub Correct()
ActivePresentation.Slides(40).Shapes(Green1).Visible = msoTrue
End Sub
Sub Wrong()
ActivePresentation.Slides(40).Shapes(Red1).Visible = msoTrue
End Sub
HOWEVER, NEITHER OF THESE ARE WORKING.
Am I calling these objects incorrectly? Any help would be appreciated.
Thanks!