+ Reply to Thread
Results 1 to 2 of 2

VBA Form Guidance

  1. #1
    Forum Contributor
    Join Date
    06-16-2010
    Location
    Tampa, FL
    MS-Off Ver
    Excel 2010
    Posts
    278

    VBA Form Guidance

    Hi,
    I'm looking for a little help in thought process - how best to make this form work.

    Form is opened when workbook opens (command button on sheet will also open form)

    Select Item1 or Item2

    Item1 - SQL query runs and gets all names to load comboNames
    choose option: namesA or namesB --loads combo box with selected type of names
    choose name from comboNames
    click the button and it runs an sql qry to get the data for that name

    Item2 also gets names, but they are different names.

    All the names are loaded to the same 2 locations (namesA and namesB sheets)

    The question: if they reload the form after the first choice, the Item1 and Item2 buttons are cleared, the names for Item1 (or Item2) are still loaded, but I'm actually going to get them again when they click on Item1 or Item2 again.

    When or how should I load/unload or check for existing names?

    Thanks!

  2. #2
    Valued Forum Contributor blane245's Avatar
    Join Date
    02-20-2009
    Location
    Melbourne, FL
    MS-Off Ver
    Excel 2010
    Posts
    649

    Re: VBA Form Guidance

    I would clear the combobox after it is used and reload it again when they select the option. Just my opinion, though.
    Bob
    Click my star if my answer helped you. Mark the thread as [SOLVED] if it has been.

+ 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