Autocomplete of combo box

Posted on 2006-05-05
Last Modified: 2012-06-27
I have programmed with MS Access/VBA for a number of years and have decided to re-write a marketed application in

What a learning curve.

Several of you have helped me immensely with a number of problems.  Almost all of which (issues) I am 100% satisfied.

I've reviewed several versions of 'autocomplete' class code examples.  None of which were truly functional or have the
'professional look and action' as the one that is inherent to MS Access.  Why wouldn't the Microsoft designers of VB take
a lesson or two from the Microsoft designers of MS Access when it comes to such a rudimentary property of a combo box?

Having said that, there is one entry on the forum here dealing with some code I am having problems with but want to test with
the hopes that it will have the look I'm hoping for.
TheLearnedOne {http:#15660554}

The following link at the beginning of his post:

' Source:

does not explicitly show how to modify for combo box.  It refers to use with a list box.  I'm assuming the code in his posting below
the 'Source:' link is specific to using a combo box.

Because of my beginner status and lack of experience with classes and commands, I don't quite understand the complete setup of
this AutoCompleteComboBox class.  At the end of TheLearnedOne's Accepted Answer he makes reference to how to set up.....but
not in an explicit way that I unfortunately need because of my lack of experience.  I do have valid code designed to a point.  But I
don't understand the integration with getting the combo box on the form.

        Private acStatus As AutoCompleteComboBox
        acStatus.Enabled = True
        acStatus.LoadWords(dsStatus, "tbl_correspondence_status", 1)

The existing combo box I have on the form at this point is set up like this and is unbound:

        With cmboStatus
            .DataSource = dtStatus
            .ValueMember = "field_order"
            .DisplayMember = "field_description"
        End With

Am I suppose to be able to drag and drop a new AutoCompleteComboBox from the toolbox?
Do I have to do everything programmatically?
I have existing combo boxes using datatables.  Do I somehow integrate them with this class?

Please help!


Question by:TSFLLC
    LVL 96

    Accepted Solution

    1) Create a class in your project
    2) Copy/paste the code from that question over the top of all the code in that class
    3) Build the solution
    4) Right-click on the toolbox
    5) Select 'Add/Remove item'
    6) Browse to the location for the project DLL (bin folder)
    7) Add the control to the toolbox
    8) Drag/drop the control on a form


    Author Comment


    Followed the directions to the T and it works well.

    So far, this seems to be the best layout.

    Thanks for the assistance.


    Featured Post

    Highfive + Dolby Voice = No More Audio Complaints!

    Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

    Join & Write a Comment

    If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
    It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
    how to add IIS SMTP to handle application/Scanner relays into office 365.

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now