Possible Combinations of scores


M

Mike

Hello all,

I'm having a really hard time with developing some VBA code to accomplish
the following:

I have a questionnaire that has 12 questions with varying possibility of
answers for each question. Based on the answers, the person will be scored
and grouped accordingly.

Here's an example of the 12 question scores:

Q1 0 2 6 6
Q2 0 1 3 4
Q3 1 2 3 4 5 6 7
Q4 1 2 3 4
Q5 1 2 3 4 5 6
Q6 2 1
Q7 1 2 3 4 5
Q8 1 2 3 4 5
Q9 1 2 3 4
Q10 1 2 3
Q11 1 2 3
Q12 5 4 3 2 1

Based on the above, I need some code that will give me a random answering of
the questions and a total of the points but I'm stumped.

Any help that anyone may be able to provide would be greatly appreciated.
Thanks in advance and have a great day,

Mike
 
Ad

Advertisements

M

mrice

Using the rnd() function and select case statements might help

X = Rnd()
Select Case X
Case Is < 1 / NumberOfOptions
Score = 1
Case Is < 2 / NumberOfOptions
Score = 2
......
.......


End Select
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top