+ Reply to Thread
Results 1 to 6 of 6

generating 6 number lotto combinations

  1. #1
    Registered User
    Join Date
    11-30-2011
    Location
    Texas
    MS-Off Ver
    Excel 2007
    Posts
    25

    generating 6 number lotto combinations

    I know I am going to get flamed for this post and told "Use the SEARCH button"......I have but can't find what I am looking for OR have ran across it maybe and I just dont understand what I have read. I dont know what a macro or vba is or how to use it, and barely know how to use excel, except for "simple" entering stuff in different cells.

    what I am wanting (trying) to do is:

    Generate all 6 number combinations ( a little over 25 million) in a 6/54 lotto.
    ie. just need one version of combination like: ex. 2-22-30-33-45-51 .... not 22-33-2-30-51-45 as these are the 'same' numbers in a different order and I dont need that.

    in the next colom next to every combination have the sum of those combinations. I'm looking mainly for combinations with sum to be between 127-203

    I hope I have explained well enough what I am after. If anyone can help me and how to apply this It would be very greatly appreciated. Sorry if the answer was in the search and I am just not sharp enough to have understood it, because I did search in this one and more forums too. (again.....very very novice-beginner at excel).

    Thanks,
    Brent

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

    Re: generating 6 number lotto combinations

    Generating them is easy.

    Aside from the fact that you'd have a 100MB file, what would you do if you had them?
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    11-30-2011
    Location
    Texas
    MS-Off Ver
    Excel 2007
    Posts
    25

    Re: generating 6 number lotto combinations

    Quote Originally Posted by shg View Post
    Generating them is easy.

    Aside from the fact that you'd have a 100MB file, what would you do if you had them?
    The size of the file is big, but ok.....use it to make a plan of what I want to play

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

    Re: generating 6 number lotto combinations

    Oops on the file size -- north of 300MB.

    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    11-30-2011
    Location
    Texas
    MS-Off Ver
    Excel 2007
    Posts
    25

    Re: generating 6 number lotto combinations

    Thanks shg....I go to tools, macros, create and paste this code in and click run... it keeps giving me 'Run-time error '1004' Application=defined or Object-defined error

    If i click the debug, it highlights in yellow
    Cells(iRow, iCol) = s5 & Format(i6, "00")

    it generates about 65000

    thank you,
    Brent

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

    Re: generating 6 number lotto combinations

    Change

    Please Login or Register  to view this content.
    to

    Please Login or Register  to view this content.
    EDIT: And that won't fit on a worksheet with 64K rows and 256 columns. Time for another plan.
    Last edited by shg; 12-19-2014 at 02:37 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. generating all possible combinations
    By tuckertuesday in forum Excel General
    Replies: 3
    Last Post: 12-10-2014, 06:24 PM
  2. generating combinations
    By fern4500 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 04-11-2012, 08:47 AM
  3. Replies: 10
    Last Post: 01-24-2012, 08:58 PM
  4. Help generating combinations
    By JamRock in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-02-2006, 03:40 PM
  5. Lotto Number Combinations
    By jgp in forum Excel General
    Replies: 0
    Last Post: 02-06-2005, 05:58 AM

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