+ Reply to Thread
Results 1 to 5 of 5

excel VBA Code for dependent combobox

  1. #1
    Registered User
    Join Date
    09-01-2009
    Location
    southampton
    MS-Off Ver
    Excel 2007
    Posts
    32

    excel VBA Code for dependent combobox

    hello,

    i have created the attached userform and i need to do some fine tuning to make it as streamlined as possible.

    Here is what i need it to do:

    when manager name Martin is selected i need the team box to show "northern"
    when manager name Ian is selected i need the team box to show "northern"
    when manager name Gavin is selected i need the team box to show "southern"
    when manager name Christine is selected i need the team box to show "southern"
    when manager name Delma is selected i need the team box to show "central"
    when manager name colette is selected i need the team box to show "central"

    at the moment they need to select the corect team from the drop down list.

    I also would like it that when the user selects "Gold target" the drop down list for branch name is populated with the list on "sheet 3". at the moment this list is empty because i cant share that information. eventually there will be lots of lists on "sheet 3" for the other partners but if i could get code for one of them i can do the rest.

    your help is greatly appreciated.

    thanks

    MattDistributions 2012 SG.xlsm
    Last edited by perrymagic; 12-11-2011 at 05:04 PM.

  2. #2
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: excel VBA Code for dependent combobox

    Hi Matt
    I've added this code to your workbook (along with several Named Ranges)
    Please Login or Register  to view this content.
    and
    Please Login or Register  to view this content.
    I'm only guessing what you want here
    I also would like it that when the user selects "Gold target" the drop down list for branch name is populated with the list on "sheet 3". at the moment this list is empty because i cant share that information. eventually there will be lots of lists on "sheet 3" for the other partners but if i could get code for one of them i can do the rest.
    Let me know of issues.
    Attached Files Attached Files
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  3. #3
    Registered User
    Join Date
    09-01-2009
    Location
    southampton
    MS-Off Ver
    Excel 2007
    Posts
    32

    Re: excel VBA Code for dependent combobox

    Hi jaslake,

    thanks very much. that is perfect!

    just one question and that is how do i set up more named ranges as i need to enter a few more columns onto sheet 3.

    i thought if i highlighted column a it would say GoldT in the cell reference but it doesnt.

    thanks again

    Matt

  4. #4
    Registered User
    Join Date
    09-01-2009
    Location
    southampton
    MS-Off Ver
    Excel 2007
    Posts
    32

    Re: excel VBA Code for dependent combobox

    actually dont worry i have found the name manager.

    thanks again. much appreciated.

  5. #5
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: excel VBA Code for dependent combobox

    Hi Matt
    You're welcome...glad I could be of help.

+ 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