Random cell?

MarkOW

New Member
Joined
Jun 26, 2018
Messages
35
Hi, Hope this makes sense to someone.

A1 = Question 1
A2 = Possible answer A
A3 = Possible answer B
A4 = Possible answer C
A5 = Possible answer D

In cells A6, A7, A8 & A9 I would like to display the contents of either A2, A3, A4 or A5 this must be in a random order as I wish to drag the formula down the sheet multiple times for around 20 questions.
Is this possible with a formula or do I need to look at vba ?

Many thanks

Marko
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
in B6:B9
=RAND()

in A6:A9
=INDEX(A$1:A$5,MATCH(SMALL(B$6:B$9,ROW()-5),B$6:B$9,0))

If you press F9 to recalculate A6:A9 B6:B9 values will change and produce a different random selection (all without duplicating)

You wont be able to drag it down 20 times, the formula will need readjusting but this is one solution to produce a random selection without producing duplicates.
I'll have a think about dragging it.

You need to define what your final output looks like, cos I can envisage several ways of doing what you've described.
 
Last edited:
Upvote 0
Hi and thanks for your help,

I looked through the forum and found this formula that does the trick.

=INDEX($C40:$F40,RAND()*4+1)

Many Thanks
 
Upvote 0
I think that will produce duplicate output if a similar random number recurs, though you havent specified anything about duplicates.
 
Upvote 0

Forum statistics

Threads
1,223,879
Messages
6,175,148
Members
452,615
Latest member
bogeys2birdies

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top