0

我有一个函数fill_cboarea(用于填充一个名为的组合框cboarea)。这个函数将调用。当Form_load到达这个fill_cboarea func调试器时, cboarea_SelectedValueChanged因为我已经在其中编写了一些代码。下面给出的是错误。

未为类型“DataRowView”和类型“整数”定义运算符“<>”

4

1 回答 1

0

你需要办理登机手续,cboarea_SelectedValueChanged

Private Sub cboarea_SelectedValueChanged(ByVal sender As Object, ByVal e As 
                             System.EventArgs) Handles cboarea.SelectedValueChanged

    Dim item As DataRowView = TryCast(Me.cboarea.SelectedItem, DataRowView)    
    If item.IsEdit = False Then'check whether the cboarea is in edit mode (on load)
       'here your some piece of code
    End If
End Sub
于 2014-08-26T09:48:24.780 回答