That's simple! You got 4 command buttons and random questions, and the money
InitQuestions:
In this sub you init the questions, give them answers and what is the right answer. An example:
CODE
strQuestion(1) = "What's my creator's display name on p2l?"
strAnswers(1, 1) = "Daredevil"
strAnswers(1, 2) = "EclipsE"
strAnswers(1, 3) = "DaCr00k"
strAnswers(1, 4) = "ZeroCool"
strAnswerIndex(1) = 2
The first line is the question you want. It'll be the first question because between ( and ) is the number 1. To init the second question you would write:
CODE
strQuestion(2) = "My question"
and so on and so on...
Beware that the number of questions is limited, there can only be 10 questions in this example because of this:
CODE
Private strQuestion(1 To 10) As String
Private strAnswerIndex(1 To 10) As Integer
Private strAnswers(1 To 10, 1 To 4) As String
You see that everywhere says 1 To 10. To make more questions change the 10 in every line to the number of questions you want to have.
Next, if you make more questions be sure to change the following lines:
CODE
currentQuestion = Int(Rnd * 11)
If currentQuestion < 1 Then currentQuestion = 1
If currentQuestion > 10 Then currentQuestion = 10
to
CODE
currentQuestion = Int(Rnd * (NumberOfQuestions + 1))
If currentQuestion < 1 Then currentQuestion = 1
If currentQuestion > NumberOfQuestions Then currentQuestion = NumberOfQuestions
replace NumberOfQuestions with how many questions do you have.
and replace this
CODE
For i = 1 To 10
with
CODE
For i = 1 To NumberOfQuesions
Again, the numberofquestions is a number that represents how much questions do you have.
Ok, let's go back to the init routine:
CODE
strAnswers(1, 1) = "Daredevil"
strAnswers(1, 2) = "EclipsE"
strAnswers(1, 3) = "DaCr00k"
strAnswers(1, 4) = "ZeroCool"
That are the possible answers to the question, and one of them is the right answer. To set some possible answers type this:
CODE
strAnswers(numQ, 1) = "answer1"
strAnswers(numQ, 2) = "answer2"
strAnswers(numQ, 3) = "answer3"
strAnswers(numQ, 4) = "answer4"
Where numQ is the question number to who you want to set the possible answers. numbers after the question number, can be 1, 2, 3 or 4. They represent the A, B, C and D answer on the command buttons. The text in the "" is the answer.
and the last thing:
CODE
strAnswerIndex(1) = 2
This means that the right answer to the question 1 is the second answer, and if you see the lines up you'll see that the second answer is EclipsE. Look at my display name... It says it all

To use the AnswerIndex
CODE
strAnswerIndex(numQ) = TheRightAnswer
numQ - the question number
TheRightAnswer - the number of the answer that is correct, can be 1, 2, 3 or 4
Ok, that's the init questions sub.
In RandomizeQuestions we do the following:
Randomize Everything with the command Randomize, this means that the program will start differently every time it is executed. Without this, the questions would be random, but always in the same order every time the program has been started.
Then we make a random number from 0 to 1 and using Rnd and then multiplying it with 11, and rounding it to a whole number using Int.
Then we check if the number is smaller than 1 and if it is, make it 1.
If the number is larger than 10, we make it 10.
And then comes the tricky part. You see, every time you give the correct answer i put the question number in a string so we would not come to that question again. Example, if i answered on questions 3, 6 and 7 the string would be like this: "|3||6||7|"
Now we check if the random number we got is a question that already was answered from the program start using InStr. We check if there is "|" the question number "|" in the string. If not, we got our next question!
But if we got it.... Well, we'll use a trick.
We'll loop from 1 to the last question and see if the question is free(not in the string). If it's not in the string we take it, set the currentQuestion and Exit For. If it's in the string we set currentQuestion to 0.
Eventually, we would go answer all questions. That's why we use currentQuestion and set it to 0. If it's 0 after the For - Next, that means no questions are left.... And you are a millionare!
I maybe left something and maybe you'll not understand everything but hey.......