Private Sub cboBody_KeyDown (KeyCode As Integer, SHIFT As Integer)
'Delete combobox entry if Del or Backspace key is hit.
If (KeyCode = 46) Or (KeyCode = 8) Then Me.cboBody = ""
End Sub
I have used identical code in the KeyDown event of my other comboboxes
to clear the box when
the delete or backspace key is pressed. It works for many identical
comboboxes just fine except
for the cboBody combo. I have looked this over and cannot find any
differences in the combobox's that are working ans the one that is
not I get the following error message?
Error: "You tried to assign the Null value to a variable that is not a
Variant data type"
Is the combobox a variable? Any ideas?
'Delete combobox entry if Del or Backspace key is hit.
If (KeyCode = 46) Or (KeyCode = 8) Then Me.cboBody = ""
End Sub
I have used identical code in the KeyDown event of my other comboboxes
to clear the box when
the delete or backspace key is pressed. It works for many identical
comboboxes just fine except
for the cboBody combo. I have looked this over and cannot find any
differences in the combobox's that are working ans the one that is
not I get the following error message?
Error: "You tried to assign the Null value to a variable that is not a
Variant data type"
Is the combobox a variable? Any ideas?
Comment