Results 1 to 4 of 4
  1. #1
    5 Star Lounger
    Join Date
    Mar 2002
    Location
    Buenos Aires, Argentina
    Posts
    877
    Thanks
    0
    Thanked 0 Times in 0 Posts

    'Stable' Random Numbers (XL2000)

    Hi,

    When I use either the RAND() or the RANDBETWEEN() functions, Excel calculates a new random number on each worksheet update (say, by pressing F9; entering a value in another cell; or even adjusting a column width, to name some). My question is, is there a way to produce "stable" random numbers without resorting to VBA? By "stable" I mean, numbers that are calculated the very first time and don't change on successive worksheet updates.

    Thank you very much
    <img src=/w3timages/blue3line.gif width=33% height=2>
    <img src=/S/flags/Argentina.gif border=0 alt=Argentina width=30 height=18> <big><font color=4682b4><font face="Comic Sans MS">Diegol</font face=comic></font color=4682b4> </big>

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: 'Stable' Random Numbers (XL2000)

    You can copy the range with the RAND or RANDBETWEEN formulas, copy it to the clipboard, then Paste Special > Values (without changing the selection). This replaces the formulas with their results.

  3. #3
    5 Star Lounger
    Join Date
    Mar 2002
    Location
    Buenos Aires, Argentina
    Posts
    877
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: 'Stable' Random Numbers (XL2000)

    Hello Hans,

    Yes, and I had read an article on how to automate the task with a macro, which was useful, but if possible I want to avoid VBA. However, just minutes from posting, I think I found an answer here. I gotta check on it a little more, but at least numbers stay still. I also found this third-party random number generator add-in, but haven't had time to try it yet (besides the hassle of the installation makes it a less attractive alternative, given the solution at hand). Thank you for your (very!) prompt response <img src=/S/thumbup.gif border=0 alt=thumbup width=15 height=15>.
    <img src=/w3timages/blue3line.gif width=33% height=2>
    <img src=/S/flags/Argentina.gif border=0 alt=Argentina width=30 height=18> <big><font color=4682b4><font face="Comic Sans MS">Diegol</font face=comic></font color=4682b4> </big>

  4. #4
    5 Star Lounger
    Join Date
    Mar 2002
    Location
    Buenos Aires, Argentina
    Posts
    877
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: 'Stable' Random Numbers (XL2000)

    In fact... the add-in did prove useful. It's very easy to use. From the website:
    <hr><UL><LI>fill the Range with random integers from the selected range
    <LI>fill the Range with random real numbers from the selected range
    <LI>fill the Range with random dates from the selected range
    <LI>fill the Range with random strings formed by symbols from the selected range
    <LI>fill the Range with random Boolean[/list]<hr>
    It's <img src=/S/free.gif border=0 alt=free width=30 height=15> and the supported versions are 2000, 2002, 2003.
    <img src=/w3timages/blue3line.gif width=33% height=2>
    <img src=/S/flags/Argentina.gif border=0 alt=Argentina width=30 height=18> <big><font color=4682b4><font face="Comic Sans MS">Diegol</font face=comic></font color=4682b4> </big>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •