>tvTree.AfterSelect += new System.WinForms.TreeViewEventHandler(this.tvTree_AfterSelect); >>If you are then unhooking the event handler can be accomplished by doing something like this.
>tvTree.AfterSelect -= new System.WinForms.TreeViewEventHandler(this.tvTree_AfterSelect); >Actually, we want to cancel a key press event. For instance we want to have a text box that will only receive numbers. When they press any other key, it does not get displayed. On the key down, we want to determine what key they pressed, and then cancel the event if it is non numeric.