+ Reply to Thread
Results 1 to 4 of 4

Combobox - can't get click event to run for first item in the list

  1. #1
    Dale
    Guest

    Combobox - can't get click event to run for first item in the list

    I created a combo box from the control toolbox toolbar. It works fine and
    the user can type in a few letters to narrow the list which displays in the
    combobox. Once the list has been shortened they will click on the item they
    want. Very handy.

    But if the item is first in the list of available items, the click doesn't
    do anything and the Click Event doesn't trigger. So my Macro -- Private Sub
    ComboBox1_Click() -- doesn't run. If the clicked item is 2nd (or further
    down) on the list the Click Event triggers fine and everything works.

    Any ideas how to get the click event to work for the first item in the list?

    Thanks!

    Dale

  2. #2
    NickHK
    Guest

    Re: Combobox - can't get click event to run for first item in the list

    Dale,
    Show you code for the _Click event.
    Are you making any check like
    If cbo1.ListIndex>0 Then...

    NickHK

    "Dale" <[email protected]> wrote in message
    news:[email protected]...
    > I created a combo box from the control toolbox toolbar. It works fine and
    > the user can type in a few letters to narrow the list which displays in

    the
    > combobox. Once the list has been shortened they will click on the item

    they
    > want. Very handy.
    >
    > But if the item is first in the list of available items, the click doesn't
    > do anything and the Click Event doesn't trigger. So my Macro -- Private

    Sub
    > ComboBox1_Click() -- doesn't run. If the clicked item is 2nd (or further
    > down) on the list the Click Event triggers fine and everything works.
    >
    > Any ideas how to get the click event to work for the first item in the

    list?
    >
    > Thanks!
    >
    > Dale




  3. #3
    Dale
    Guest

    Re: Combobox - can't get click event to run for first item in the

    Here's the code I have for the experimental combobox:
    Private Sub ComboBox1_Click()
    MsgBox "click"
    End Sub

    Not too exciting.
    I'm not doing any checking. It sounds like maybe I should?...

    Thanks!
    Dale

    "NickHK" wrote:

    > Dale,
    > Show you code for the _Click event.
    > Are you making any check like
    > If cbo1.ListIndex>0 Then...
    >
    > NickHK
    >
    > "Dale" <[email protected]> wrote in message
    > news:[email protected]...
    > > I created a combo box from the control toolbox toolbar. It works fine and
    > > the user can type in a few letters to narrow the list which displays in

    > the
    > > combobox. Once the list has been shortened they will click on the item

    > they
    > > want. Very handy.
    > >
    > > But if the item is first in the list of available items, the click doesn't
    > > do anything and the Click Event doesn't trigger. So my Macro -- Private

    > Sub
    > > ComboBox1_Click() -- doesn't run. If the clicked item is 2nd (or further
    > > down) on the list the Click Event triggers fine and everything works.
    > >
    > > Any ideas how to get the click event to work for the first item in the

    > list?
    > >
    > > Thanks!
    > >
    > > Dale

    >
    >
    >


  4. #4
    NickHK
    Guest

    Re: Combobox - can't get click event to run for first item in the

    Dale,
    I see no reason why the Click event does not work for the first item in the
    list, but works for all others.

    NickHK

    "Dale" <[email protected]> wrote in message
    news:[email protected]...
    > Here's the code I have for the experimental combobox:
    > Private Sub ComboBox1_Click()
    > MsgBox "click"
    > End Sub
    >
    > Not too exciting.
    > I'm not doing any checking. It sounds like maybe I should?...
    >
    > Thanks!
    > Dale
    >
    > "NickHK" wrote:
    >
    > > Dale,
    > > Show you code for the _Click event.
    > > Are you making any check like
    > > If cbo1.ListIndex>0 Then...
    > >
    > > NickHK
    > >
    > > "Dale" <[email protected]> wrote in message
    > > news:[email protected]...
    > > > I created a combo box from the control toolbox toolbar. It works fine

    and
    > > > the user can type in a few letters to narrow the list which displays

    in
    > > the
    > > > combobox. Once the list has been shortened they will click on the

    item
    > > they
    > > > want. Very handy.
    > > >
    > > > But if the item is first in the list of available items, the click

    doesn't
    > > > do anything and the Click Event doesn't trigger. So my Macro --

    Private
    > > Sub
    > > > ComboBox1_Click() -- doesn't run. If the clicked item is 2nd (or

    further
    > > > down) on the list the Click Event triggers fine and everything works.
    > > >
    > > > Any ideas how to get the click event to work for the first item in the

    > > list?
    > > >
    > > > Thanks!
    > > >
    > > > Dale

    > >
    > >
    > >




+ 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