'Why is Winforms TreeNode Click event not firing when plus/minus button is clicked causing node to move?
I'm working on a Winforms C# application and am using the TreeView and TreeNode classes to build a file browser. It all seems to work fine except in certain cases when I click the plus/minus box. I know it's part of the node and should fire the node's click event as well, and that indeed does happen. There are cases though when the expansion or collapse of the node goes beyond the boundaries of the TreeView causing the scrollbar to shift. If this also causes the clicked node to shift its location on the screen, the node's click event doesn't fire.
"source" doesn't change position when expanded. Click event fires as normal.
"Videos" moves up the screen slightly to show child node. Click event fails to fire.
I haven't been able to find any info on this issue.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
