Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

[VB.NET] Generate Random Numbers by Given Range and Given Average

Avatar of Giulia Ayumi
Giulia AyumiFlag for Brazil asked on
Visual Basic.NET* DataGridView* Generators
13 Comments1 Solution386 ViewsLast Modified:
Hello Experts!

I'm trying to do a little function for my app, but i really don't know to do it.


I want to do a function where i give it a range (Min / Max), Average and How many records like:

Min: 67.9
Max: 101.9
Records: 5
Average: 74.4

So it should generate into my DataGridView1 (Or DataTable) 5 records of numbers with a final average of 74.4.

The Result:

Average: 74.4

How can i do this?
Avatar of Mike Tomlinson
Mike TomlinsonFlag of United States of America imageHigh School Computer Science, Computer Applications, Digital Design, and Mathematics Teacher
This problem has been solved!
Unlock 1 Answer and 13 Comments.
See Answers