MyForm has a treeview control, I want this treeview to be readonly. But if the user click on one of the form's context menu item, I also want to allow user to use their mouse or (shift+arrow key) to select the text in a node, copy them and paste to other document.
The problem is when user click on a node and choose to copy, he could select and copy, but he could also type into the node. Although I do something in AfterLabelEdit event to cancel all the changes that made to this node, it is kind of misleading. I want to prevent all keyboard input except Shift+arrow, which is for selecting. But I simple couldn't find a way to do it.
I tried AddHandler for keydown, keypress, keyup events, but still catch nothing.
Help! And thanks!
The problem is when user click on a node and choose to copy, he could select and copy, but he could also type into the node. Although I do something in AfterLabelEdit event to cancel all the changes that made to this node, it is kind of misleading. I want to prevent all keyboard input except Shift+arrow, which is for selecting. But I simple couldn't find a way to do it.
I tried AddHandler for keydown, keypress, keyup events, but still catch nothing.
Help! And thanks!