How to get Selected Value of DatagridviewComboboxColumn

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • syedfasih
    New Member
    • Feb 2007
    • 10

    How to get Selected Value of DatagridviewComboboxColumn

    I am working on a Saloon Application in which I am generation the appointment system, I have a column in a Gridview in which a ComboboxColumn is embeded that contains services that saloon provides. I have to take some action on selection of the combobox value. I am unabel to do so, I have trapped the SelectedIndexCh anged event but unable to use it in proper manner, here is the code:

    Private Sub DataGridView1_E ditingControlSh owing(ByVal sender As System.Object, ByVal e As System.Windows. Forms.DataGridV iewEditingContr olShowingEventA rgs) Handles DataGridView1.E ditingControlSh owing
    Dim ServiceCombo As ComboBox = TryCast(Me.Data GridView1.Editi ngControl, ComboBox)
    If ServiceCombo IsNot Nothing Then
    AddHandler ServiceCombo.Se lectedIndexChan ged, AddressOf ComboBox_Select edIndexChanged
    End If
    End Sub

    Private Sub ComboBox_Select edIndexChanged( ByVal sender As System.Object, ByVal e As System.EventArg s)
    MessageBox.Show ("OK")
    End Sub

    Please help me ragarding...... .
  • syedfasih
    New Member
    • Feb 2007
    • 10

    #2
    I have solved the problem.... :)

    Comment

    Working...