The enter key in the key down event

1 posts, 0 answers
  1. simeon
    simeon avatar
    12 posts
    Member since:
    Sep 2008

    Posted 08 Sep 2009 Link to this post

    We have a treeview that is displaying a menu for our application.  What I would like to be able to do is when we press the enter key on a node that does not have any children is handle the enter key press in code behind.  The default behavoiur does not allow this to happen as the enter key does not seem to get passed to the key_down event.  I presume this is by design as the other control keys (+-/*) dont raise the key_down event as well.  Any idea's how to work around this?  As the enter key is the natural key to press to our users to start navigation.

    EDIT

    (Nevermind got to stop thinking like a winform programmer you simply handle the keyup as that event seems to be bubbled through and it works cool)


    Cheers,

    Simeon
Back to Top