G
Geoff Cox
Hello,
The following code is used to fill a CoomboBox. The user makes the
correct selection and then moves on to the next slide.
At the moment the first ComboBox has the number 2 in it, the second
the number 1 in it and the third the number 2.
How do I make sure that the boxes are empty before a macro is run to
populate the boxes with the various possible answers?
Cheers
Geoff
Private Sub Initialize()
If ComboBox1.ListCount = 5 Then GoTo Check
ComboBox1.AddItem "Select"
ComboBox1.AddItem "charges"
ComboBox1.AddItem "costs"
ComboBox1.AddItem "revenue"
ComboBox1.AddItem "price"
Check:
ComboBox1.Style = fmStyleDropDownList
ComboBox1.BoundColumn = 0
ComboBox1.ListIndex = 0
End Sub
Private Sub ComboBox1_Click()
Select Case ComboBox1.Value
Case 0
Label1.Caption = "What's your Answer?"
Case 1
Label1.Caption = "No, try again."
Case 2
Label1.Caption = "Well done, this is the associated word."
Case 3
Label1.Caption = "No, try again."
Case 4
Label1.Caption = "No, try again."
End Select
End Sub
Sub object_mouse_over()
Initialize
End Sub
The following code is used to fill a CoomboBox. The user makes the
correct selection and then moves on to the next slide.
At the moment the first ComboBox has the number 2 in it, the second
the number 1 in it and the third the number 2.
How do I make sure that the boxes are empty before a macro is run to
populate the boxes with the various possible answers?
Cheers
Geoff
Private Sub Initialize()
If ComboBox1.ListCount = 5 Then GoTo Check
ComboBox1.AddItem "Select"
ComboBox1.AddItem "charges"
ComboBox1.AddItem "costs"
ComboBox1.AddItem "revenue"
ComboBox1.AddItem "price"
Check:
ComboBox1.Style = fmStyleDropDownList
ComboBox1.BoundColumn = 0
ComboBox1.ListIndex = 0
End Sub
Private Sub ComboBox1_Click()
Select Case ComboBox1.Value
Case 0
Label1.Caption = "What's your Answer?"
Case 1
Label1.Caption = "No, try again."
Case 2
Label1.Caption = "Well done, this is the associated word."
Case 3
Label1.Caption = "No, try again."
Case 4
Label1.Caption = "No, try again."
End Select
End Sub
Sub object_mouse_over()
Initialize
End Sub