By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
444,219 Members | 2,147 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 444,219 IT Pros & Developers. It's quick & easy.

>>>>Strange grid cell events .net 2003

P: n/a
I upgraded from .NET 2002 to .NET 2003 and found one weird
things on the LEAVE / ENTER events within a datagrid. I
added handler to each textbox of a datagrid, then handle
the ENTER/LEAVE events. The ENETER/LEAVE events used to
work normally with all arrows keys in 2002 version. Just
after upgraded to 2003:
1. up/down key on same column DON'T fire enter/leave!
2. READONLY on column fire events, but when editable,
events not fire
3. Click in and out of cell fire events,but not up/down
arrow keys!
(i turned off the keypreview off actually)
Now all my compnay projects' datagrid face the same
problem!! Does anyone know how come same piece of code not
work in 2003? PLS. HELP! Thank you!

Code ---------------------
Dim c As Control

For Each c In dgAttTaking.Controls
If TypeOf c Is DataGridTextBox Then
AddHandler c.Enter, AddressOf EnterTextBox
AddHandler c.Leave, AddressOf LeaveTextBox
End If
Next
:
:
Private Sub EnterTextBox(ByVal sender As Object, ByVal
e As System.EventArgs)
.... do something

End Sub

Private Sub LeaveTextBox(ByVal sender As Object, ByVal
e As System.EventArgs)
.... do something
End Sub
-----------------Code ends
Nov 20 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.