+ Reply to Thread
Results 1 to 3 of 3

Multiple ComboBox

  1. #1
    Registered User
    Join Date
    06-20-2011
    Location
    USA
    MS-Off Ver
    Excel 2003
    Posts
    3

    Multiple ComboBox

    Newer to VBA

    I have a UserForm with 2 ComboBox options. It gives the Month and the Year. I also have a line of code that I want the UserForm to run depending on what Month and Year are choose.

    How do I get the code to say....If May and 2011 are chosen, then the May 2011 code is run. If June and 2012 are chosen, then the June 2012 code is run.

    The code is a recorded marcro that goes to a pivot table from anoter file and filters the table to certain criteria (including month and year) and copies subtotals and pastes them in the current workbook. Will this go in a module or in the UserForm (Code).

    Again, I am very new to Macros and don't know much. I have learned everything from recording macros, looking at forums, and skimming through "Excel Macros VBA for Dummy's." However, I am still stuck.

  2. #2
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Multiple ComboBox

    Is the macro named May 2011? If it is try this
    Attached Files Attached Files
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  3. #3
    Registered User
    Join Date
    06-20-2011
    Location
    USA
    MS-Off Ver
    Excel 2003
    Posts
    3

    Re: Multiple ComboBox

    RoyUK, I didn't see any Macros on the file.

+ 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