Table没有只读属性,只能使用KeyDown或KeyPress事件来处理
- Private Sub Textcontrol1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles Textcontrol1.KeyPress
- If Not Textcontrol1.Tables.GetItem Is Nothing Then
- e.Handled = False
- Else
- e.Handled = True
- End If
- End Sub
复制代码 |