RAND Function

papal singh

New Member
May 13, 2014
so I've got this code which uses the RAND function and it keeps on re calculating every time, is there any way I can stop this or use some other similar function?


Active Member
Oct 25, 2013
You have to be more specific or you won't get any help. What is the code? What function is it serving?


Board Regular
May 14, 2007
The RAND function will always generate a new random number every time the workbook calculates.

I'm not sure what your needs are, but there are two ways that this could go.

1) Use the RAND function to generate a random number. Copy > Paste Special as Values to remove the formula. Use a reference to that result in your formula.

This methodology has the benefit of remaining static under workbook calculation. If you ever needed a new random number, you could use the RAND function again in that same cell, to which your larger formula has a reference.

2) Disable auto calculation.

Because no calculations are being performed, the RAND would not keep changing. If you ever wanted to calculate your workbook, you could calculate manually using F9. However, this would generate a new random number as well as calculating the rest of the formulas.

If neither of these work for you, then we would need more information about what you're trying to accomplish.

Forum statistics

Latest member

Some videos you may like

This Week's Hot Topics

  • populate from drop list with multiple tables
    Hi All, i have a drop list that displays data, what i want is when i select one of those from the list to populate text from different tables on...
  • Find list of words from sheet2 in sheet1 before a comma and extract text vba
    Hi Friends, Trying to find the solution on my task. But did not find suitable one to the need. Here is my query and sample file with details...
  • Dynamic Formula entry - VBA code sought
    Hello, really hope one of you experts can help with this - i've spent hours on this and getting no-where. .I have a set of data (more rows than...
  • Listbox Header
    Have a named range called "AccidentsHeader" Within my code I have: [CODE]Private Sub CommandButton1_Click() ListBox1.RowSource =...
  • Complex Heat Map using conditional formatting
    Good day excel world. I have a concern. Below link have a list of countries that carries each country unique data. [URL...
  • Conditional formatting
    Hi good morning, hope you can help me please, I have cells P4:P54 and if this cell is equal to 1 then i want row O to say "Fully Utilised" and to...