Results 1 to 9 of 9

Secondary list box populated based on selection in previous list box

Threaded View

  1. #1
    Registered User
    Join Date
    10-19-2012
    Location
    Minnesota
    MS-Off Ver
    Excel 2010
    Posts
    16

    Question Secondary list box populated based on selection in previous list box

    My apologies. Many thanks for your help. I have attached an example workbook. Here is the tagged code:

    Private Sub workbook_Open()
    
    Sheet1.ListBoxFacilities.Clear
        
        With Sheet1.ListBoxFacilities
            .AddItem "ANW Programs and Instititutes"
            .AddItem "Buffalo Programs and Instititutes"
            .AddItem "Mercy Programs and Instititutes"
            .AddItem "United Programs and Instititutes"
        End With
        
    End Sub
    Private Sub ListBoxFacilities_Click()
    
        Sheets("Institutes").Select
        
        With Sheets("Institutes").ListBoxPrograms
                .Clear
                    Select Case Range("Facility").Text
                        Case Is = "ANW Programs and Institutes"
                            .AddItem "Bariatric Center"
                            .AddItem "Courage Institute"
                            .AddItem "Oxygen Center"
                            .AddItem "Infusion Center"
    
                        Case Is = "Buffalo Programs and Institutes"
                            .AddItem "Kidney Program"
                            .AddItem "Smoking Cessation"
    
                        Case Is = "Mercy Programs and Institutes"
                            .AddItem "Mercy Center"
                            .AddItem "Rehabilitation Institute"
                            .AddItem "Hyperbaric Oxygen Center"
    
                        Case Is = "United Programs and Institutes"
                            .AddItem "United Center"
                            .AddItem "Infusion Center"
                            .AddItem "Insomnia and Behavioral Sleep Medicine"
                            .AddItem "LiveWell Fitness Center"
                            .AddItem "Lung Nodule Clinic"
        End With
    End Sub
    Attached Files Attached Files
    Last edited by seleseped; 03-06-2017 at 02:11 PM. Reason: forgot to add code tags

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Pre-populated drop-down list from selection made in drop-down list
    By jmaggols in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-15-2015, 12:26 PM
  2. [SOLVED] Change next ComboBox list based on previous ComboBox selection
    By SteveTheFish in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-26-2015, 11:23 PM
  3. Replies: 10
    Last Post: 12-19-2014, 07:14 PM
  4. Populate Drop-down list based on selection from previous drop-down list
    By Diventus in forum Excel - New Users/Basics
    Replies: 14
    Last Post: 01-11-2013, 10:55 AM
  5. Populate Drop-down list based on selection from previous drop-down list
    By poison_stone in forum Excel - New Users/Basics
    Replies: 3
    Last Post: 12-11-2012, 06:10 PM
  6. Replies: 3
    Last Post: 09-29-2011, 02:21 PM
  7. how to populate field based on previous drop down list selection?
    By ItsAllGood in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-20-2007, 01:57 AM

Tags for this Thread

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