Click here to Skip to main content
15,905,607 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,

I am asking again the same qns because i cant get too much from last one.
I am using TreeView In WPF but there is no treeview_NodeMouseClick Event. there are too may events in WPF but not this or similar to this.

// WIndows Application
C#
private void treeview_NodeMouseClick(object sender, TreeNodeMouseClickEventArgs e)
        {
            if (e.Node != null)
            {
                GetAllchield(e.Node, e.Node.Level);

            }

        }


I want similar in WPF PLease help me regarding this.

Thanks
Neetesh Agarwal
Posted
Updated 10-May-12 1:43am
v2

1 solution

The normal way to achieve this in WPF is to follow the MVVM pattern, and bind a click method to the nodes using one of the many ICommand derived commanding classes (such as RelayCommand).
 
Share this answer
 
Comments
Neetesh Agarwal 10-May-12 8:09am    
Thanks , Can u give me any link. I am new in WPF need to study hard in it.
Pete O'Hanlon 10-May-12 8:14am    
I would start with this article and then look at something like the MVVM light toolkit to get you some of the infrastructure you will end up using on a day to day basis with MVVM.
Neetesh Agarwal 10-May-12 8:20am    
Thanks a lot.....

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