Results 1 to 4 of 4

Thread: Combobox click event

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Oct 2002
    Posts
    67

    Combobox click event

    Ok since I started using vb.net I have failed to make the click event on a combobox fire. I have till this point been able to getaway with using other events for my deired result. Now, I can not. Does anyone have any clue what it takes to make a click event fire in vb.net?

    Private Sub Combobox1_click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Database.SelectedIndexChanged

    End Sub


    Does not work

  2. #2
    Sleep mode
    Join Date
    Aug 2002
    Location
    RUH
    Posts
    8,083
    I've tried this and worked fine (with dropstyle set to all options though)
    VB Code:
    1. Private Sub ComboBox1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles ComboBox1.Click
    2.         MessageBox.Show("Click event was fired")
    3. End Sub

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Oct 2002
    Posts
    67
    intresting... thankyou.

  4. #4
    Fanatic Member VBCrazyCoder's Avatar
    Join Date
    Apr 2003
    Posts
    681
    You were using the SelectedIndexChanged event, which is fired when the user changes the item in the cbo box, not when they just click on it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width