G
Guest
There is an article with an example on this topic. ( article 323167).
The example works good if the datagrid column is string type. Here is a portion of code that handles text changed:
------------------------------
Private Sub Ctrls_TextChanged(ByVal sender As Object, ByVal e As System.EventArgs)
If DataGrid1.CurrentCell.ColumnNumber = 3 Then
MyCombo.Visible = False
If DataGrid1.Item(DataGrid1.CurrentCell) & "" = "" Then
SendKeys.Send("*")
End If
DataGrid1.Item(DataGrid1.CurrentCell) = MyCombo.Text
End If
End Sub
---------------------
I have problem to make this work for column with integer type. When I select an integer from the combobox, the screen freezes, error either in SendKeys.Send("*")
or DataGrid1.Item(DataGrid1.CurrentCell) = MyCombo.Text complaining about data type.
Any hits are welcome.
Jenny
The example works good if the datagrid column is string type. Here is a portion of code that handles text changed:
------------------------------
Private Sub Ctrls_TextChanged(ByVal sender As Object, ByVal e As System.EventArgs)
If DataGrid1.CurrentCell.ColumnNumber = 3 Then
MyCombo.Visible = False
If DataGrid1.Item(DataGrid1.CurrentCell) & "" = "" Then
SendKeys.Send("*")
End If
DataGrid1.Item(DataGrid1.CurrentCell) = MyCombo.Text
End If
End Sub
---------------------
I have problem to make this work for column with integer type. When I select an integer from the combobox, the screen freezes, error either in SendKeys.Send("*")
or DataGrid1.Item(DataGrid1.CurrentCell) = MyCombo.Text complaining about data type.
Any hits are welcome.
Jenny