Click here to Skip to main content
15,949,741 members
Please Sign up or sign in to vote.
4.33/5 (3 votes)
See more:
I have a Windows.Forms.Treeview object on a Form. If I expand a node on the tree that extends that nodes children past the bottom of the form I do not receive the NodeMouseClick event? Any ideas of what I can do to have the NodeMouseClick event fire, or why it is not?
Posted

I would use AfterExpand or BeforeExpand (-Collapse) methods and trigger the same functionality as on Click.
 
Share this answer
 
I know what's happening. The node is moved upward and away from under the mouse and this happens a soon as the MouseDown is received. Thus it does not receive the mouse key up event and thus cannot generate a NodeMouseClick because a Click does need both events:
MouseDown and MouseUp.

As to how to alleviate this I currently don't have any idea.

Just to make things worse, same happens when you collapse a node and
it moves away from under the mouse because of that.



Cheers

Manfred
 
Share this answer
 
v6

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900