# VB newbie!  Random forms

**URL:** <https://boards.straightdope.com/t/vb-newbie-random-forms/67628>\
**Category:** Factual Questions\
**Created:** [June 5, 2001, 4:14am UTC](https://boards.straightdope.com/t/vb-newbie-random-forms/67628 "2001-06-05T04:14:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cykrider](https://avatars.discourse-cdn.com/v4/letter/c/f19dbf/32.png) [@cykrider](https://boards.straightdope.com/u/cykrider)\
**Post date:** [June 5, 2001, 4:14am UTC](https://boards.straightdope.com/t/vb-newbie-random-forms/67628/1 "2001-06-05T04:14:51Z")

</div>

I’m making a program on VB 6.0 that will test me on various information. The problem is I want the questions to come up in a random order. I put each question on a seperate form (can you think of any other way of doing this, it might take forever if I have 100 questions!) and I’d like a random form to come up instead of asking the same questions in the same order. Thanks.

---

<div class="post-metadata">

**Author:** ![Azura\_Borealis](https://avatars.discourse-cdn.com/v4/letter/a/7ab992/32.png) [@Azura\_Borealis](https://boards.straightdope.com/u/Azura_Borealis)\
**Post date:** [June 5, 2001, 5:49am UTC](https://boards.straightdope.com/t/vb-newbie-random-forms/67628/2 "2001-06-05T05:49:32Z")

</div>

[Try Looking Here](http://www.insteptech.com/vbtips.htm)

I am the worlds worst when it comes to describing anything technical, So I’ll spare you the trauma of attempting to understand my jibberish.

😃

---

<div class="post-metadata">

**Author:** ![hardcore](https://avatars.discourse-cdn.com/v4/letter/h/b5a626/32.png) [@hardcore](https://boards.straightdope.com/u/hardcore)\
**Post date:** [June 5, 2001, 8:15am UTC](https://boards.straightdope.com/t/vb-newbie-random-forms/67628/3 "2001-06-05T08:15:45Z")

</div>

I recommend using a database with all of the questions in it, numbered 1 - 100, then generating the non-repeating, random sequence of the questions at runtime. In other words, generate a random number between 1 - 100, and this will be the first question. Then generate a number between 1 - 99, and this will be the second. Continue this loop until you have finished the question number sequence.

I would use one form with a scroll bar, much like a web page. However, this would require a lot of scrolling on the user’s part, especially for 100 questions. If you only want one question on a form at a time, just use 1 form, but keep changing the question on the form at runtime after each question is answered.
