+ Reply to Thread
Results 1 to 14 of 14

Number Generator

Hybrid View

  1. #1
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Number Generator

    there is a typo in the code the first line should read
    Function aiComboByNum(ByVal n As Long, ByVal t As Long, ByVal cNum As Long)
    dont forget to array enter it with ctrl+shift+ enter
    see here
    http://office.microsoft.com/en-us/ex...872901033.aspx
    Last edited by martindwilson; 01-10-2010 at 10:57 AM.
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Number Generator

    Quote Originally Posted by Chris
    I went to the blank work sheet and entered: =aiComboByNum(75, 4, RANDBETWEEN(0, COMBIN(75, 4) - 1))
    and the result is : #NAME?
    Sounds like you didn't get the code installed. See attached. Before you open the workbook, set macro security to Disable all macros with notification, and then enable macros when prompted.

    Quote Originally Posted by Martin
    there is a typo in the code the first line should read
    There's no typo, Martin, it's correct as written.

    Quote Originally Posted by Martin
    dont forget to array enter it with ctrl+shift+ enter
    True, thanks for the emphasis.
    Attached Files Attached Files
    Entia non sunt multiplicanda sine necessitate

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1