Hi Ger.
The F6 function key will erase the DateBox contents.
I have inherited the DataBox into my own DateBox and added some functionality, one of them being the ability to use the Del key to perform this same action.
Here is the code if you decide to go for it:
Protected Overrides Function ProcessCmdKey(ByRef msg As System.Windows.Forms.Message, ByVal keyData As System.Windows.Forms.Keys) As Boolean
Select Case keyData
Case Keys.Delete
'-- Delete key pressed, send an F6 to clear contents
Return MyBase.ProcessCmdKey(msg, Keys.F6)
End Select
Try
Return MyBase.ProcessCmdKey(msg, keyData)
Catch ex As Exception
'-- the DateBox will throw an exception if user use keys to add or subtract beyond the bounderies
' so in these cases we will just send Home key
Return MyBase.ProcessCmdKey(msg, Keys.Home)
End Try
End Function
Hope it helps.