+ Reply to Thread
Results 1 to 2 of 2

Problem with generating Combinations (Myrna Larson macro)

  1. #1
    Registered User
    Join Date
    01-20-2012
    Location
    Singapore
    MS-Off Ver
    Excel 2007
    Posts
    1

    Problem with generating Combinations (Myrna Larson macro)

    Hi,

    I have been to numerous forums where they discuss combinations/permutations macro by Myrna Larson, and reasons why it might not work. Unfortunately I didn't find solution for my issue.


    As required by the macro, I inserted C into A1 (for choosing combinations); A2 = 2 (for pairs) and A3:A8 variables to be combined. (although irrelevant, I am interested in generating pairs)

    First I get "Compile error: Sub or formula not defined" highlighting: If FlushBuffer = True Or BufferPtr = UBound(Buffer()) Then


    Secondly I get "Compile error: Invalid Redim" highlighting: ReDim Buffer(1 To UBound(Buffer))

    Could you please help me with these? How to resolve the issues so that the macro will generate the combinations(I am only interested in the combinations, not the permutations). I've got 2007 Excel, and am a bit new to the VBA.

    The original Myrna Larson macro is as follows:

    Please Login or Register  to view this content.
    Last edited by Excelstudent12; 01-20-2012 at 04:40 AM.

  2. #2
    Forum Expert snb's Avatar
    Join Date
    05-09-2010
    Location
    VBA
    MS-Off Ver
    Redhat
    Posts
    5,649

    Re: Problem with generating Combinations (Myrna Larson macro)

    Please read the forum rules first and above all: use codetags ~!



+ 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