When you’re testing a workbook it is handy to be able to fill a set of cells with a sample value. The Randbetween function included in the Analysis Tookpak does this for you.
To enable this, choose Tools, Add-Ins and enable the checkbox for the Analysis Toolpak. Now write the function, for example, this provides a random number between 1 and 100 (including both numbers):
Copy it to all the cells to fill. To fix the values so they don’t change each time something in the worksheet changes, select the cells with the formula, choose Edit, Copy then Edit, Paste Special, Values.