Results 1 to 6 of 6

Skip number in sequence

Threaded View

ldoodle Skip number in sequence 11-17-2016, 07:38 AM
sourabhg98 Re: Skip number in sequence 11-17-2016, 08:12 AM
ldoodle Re: Skip number in sequence 11-17-2016, 08:32 AM
sourabhg98 Re: Skip number in sequence 11-17-2016, 08:45 AM
ldoodle Re: Skip number in sequence 11-18-2016, 08:52 AM
ldoodle Re: Skip number in sequence 11-17-2016, 08:52 AM
  1. #1
    Registered User
    Join Date
    11-09-2016
    Location
    London, England
    MS-Off Ver
    2010/2016
    Posts
    74

    Skip number in sequence

    Hey,

    I'm doing this:

    Rand = WorksheetFunction.Choose(WorksheetFunction.RandBetween(1, count), 5, 10, 15, 20, 25, 35, 40, 45, 50, 55, 60)
    The values for CHOOSE are hard coded at the moment, but I need them to be dynamic. The count parameter for RandBetween is a cell value. This could change, and then in turn the number of values for CHOOSE.

    If the start number is, in this case, 5, how would I get the next values to be mulpitples of 5? The start number can be anything, and is based on a rounded division of a total value and a count value.

    So:

    if the total is 68 and count is 11 the result is 6.18, rounded to 6. So there should be 11 multiples of 6 for the values for CHOOSE.

    If the total is 70 and the count is 10, the result is 7. So there should be 10 mulitples of 7 for the values for CHOOSE.

    Building the string of values I can do. But using that string (comma separated) in CHOOSE doesn't work.

    Is that possible? To pass a dynamic number of arguments to CHOOSE?

    Thanks!
    Last edited by ldoodle; 11-17-2016 at 07:51 AM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 7
    Last Post: 06-08-2015, 08:39 AM
  2. How do you fill a series of cell references and skip four to produce a sequence
    By john dalton in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-02-2014, 07:25 AM
  3. [SOLVED] Function to skip the process if the sequence number is missing
    By Thinker8 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-15-2014, 08:20 AM
  4. Replies: 6
    Last Post: 11-26-2013, 05:21 PM
  5. Replies: 5
    Last Post: 11-22-2010, 06:31 PM
  6. [SOLVED] How can I match a random number with closest number from sequence?
    By matt in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-02-2006, 08:25 PM

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