Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4  
Old 01-06-2016, 02:45 PM
NoSparks NoSparks is offline Excel Combobox List Windows 7 64bit Excel Combobox List Office 2010 64bit
Excel Hobbyist
 
Join Date: Nov 2013
Location: British Columbia, Canada
Posts: 842
NoSparks is a glorious beacon of lightNoSparks is a glorious beacon of lightNoSparks is a glorious beacon of lightNoSparks is a glorious beacon of lightNoSparks is a glorious beacon of light
Default

I'm not sure I follow what you're doing, and definitely don't follow when it's being done.
Using the _Change() event will fire the FillCombobox procedure every time any character is typed into the combo box.
I'd think you would want the drop downs to populate before entering anything.
Perhaps using the _GotFocus event instead of _Change.
Code:
Private Sub ComboBox1_GotFocus()
    Call FillCombobox("List", "A", Me.ComboBox1)
End Sub
and like this for the FillCombobox procedure
Code:
Sub FillCombobox(WSName As String, ColLtr As String, CBox As ComboBox)
    Dim LastRow As Long
Set ws = ActiveWorkbook.Worksheets("List")
With ws
    LastRow = .Cells(.Rows.Count, ColLtr).End(xlUp).Row
    CBox.List = .Range(ColLtr & "3:" & ColLtr & LastRow).Value
End With
End Sub
Reply With Quote
 

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel Combobox List Using combobox to pass data from an Excel spread sheet to text boxes on userform Stewie840 Word VBA 14 12-17-2015 10:13 PM
Excel Combobox List combobox list gets reset....please help Deepa Shrestha Word VBA 1 09-29-2013 09:30 PM
Excel Combobox List VB code: populate combobox from columns in Excel file billybeach Outlook 2 04-27-2013 04:38 AM
Excel Combobox List Adding a long list of values to a combobox in Word 2003? ll4u76 Word VBA 1 04-13-2012 03:37 AM
Excel Combobox List Populating ComboBox or Drop Down list with contents of a text field Billy_McSkintos Word VBA 1 09-13-2011 05:50 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 09:25 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft